Literal languages are lost on repeated `#<<` calls
Created by: no-reply
We lose language values when setting using existing values. This affects #<<
, and #set
calls when a Relation
is the argument.
require 'rdf/vocab'
class Book
include ActiveTriples::RDFSource
property :title, predicate: RDF::Vocab::DC.title
end
book = Book.new
book.title << RDF::Literal("Moomin", language: :en)
book.title << RDF::Literal("Mummi", language: :fi)
book.dump :ttl
# => "\n [ <http://purl.org/dc/terms/title> \"Moomin\",\n \"Mummi\"@fi] .\n"