Remove pragmatic_context from Universes

This commit is contained in:
Robert Richter 2016-09-06 18:50:42 -05:00
parent a90dda4f27
commit b17f3fb108
No known key found for this signature in database
GPG Key ID: BEC39BF873A0103B

View File

@ -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,