mirror of
https://github.com/indentlabs/notebook.git
synced 2025-10-26 11:19:22 +00:00
Remove pragmatic_context from Universes
This commit is contained in:
parent
a90dda4f27
commit
b17f3fb108
@ -6,7 +6,6 @@
|
||||
#
|
||||
# contains all canonically-related content created by Users
|
||||
class Universe < ActiveRecord::Base
|
||||
include PragmaticContext::Contextualizable
|
||||
validates :name, presence: true
|
||||
|
||||
belongs_to :user
|
||||
@ -16,17 +15,6 @@ class Universe < ActiveRecord::Base
|
||||
|
||||
scope :is_public, -> { where(privacy: "public") }
|
||||
|
||||
# Used for JSON-LD generation
|
||||
contextualize_as_type 'http://schema.org/CreativeWork'
|
||||
contextualize_with_id { |universe| Rails.application.routes.url_helpers.universe_url(universe) }
|
||||
contextualize :user, as: 'http://schema.org/author'
|
||||
contextualize :user, as: 'http://schema.org/copyrightHolder'
|
||||
contextualize :characters, as: 'http://schema.org/character'
|
||||
contextualize :items, as: 'http://schema.org/hasPart'
|
||||
contextualize :locations, as: 'http://schema.org/hasPart'
|
||||
contextualize :name, :as => 'http://schema.org/name'
|
||||
contextualize :description, :as => 'http://schema.org/description'
|
||||
|
||||
def content_count
|
||||
[
|
||||
characters.length,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user