Skip to content

Commit

Permalink
merge solrizer and rdf_label
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom Johnson committed Dec 6, 2013
1 parent 28a26a1 commit b01c415
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions lib/oregon_digital/rdf/rdf_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,11 @@ def type=(type)
end

def rdf_label
get_values(self.class.rdf_label)
values = get_values(self.class.rdf_label)
values = rdf_subject.to_s unless node? if values.empty?
return values
end
alias_method :solrize, :rdf_label

def persist!(parent=nil)
repo = parent
Expand Down Expand Up @@ -174,12 +177,6 @@ def set_subject!(uri_or_str)
end
end

def solrize
return rdf_label unless rdf_label.empty?
return rdf_subject.to_s unless node?
# how to solrize bnodes without labels?
end

private

def predicate_for_property(property)
Expand Down

0 comments on commit b01c415

Please sign in to comment.