Last active
August 2, 2016 16:43
-
-
Save elrayle/c78c8458e7bc6ccc9b31a865dae4f9cb to your computer and use it in GitHub Desktop.
Problems and potential workarounds for annotation's body being nil
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # defined in Annotation | |
| # NOTE: No class defined, so holds URI string only | |
| property :hasBody, :predicate => RDF::Vocab::OA.hasBody | |
| # in PRY | |
| generic_annotation = Annotation.new(uri_or_str) | |
| body_uri = generic_annotation.hasBody | |
| body = ActiveTriples::Resource(body_uri) | |
| body.statements # => [] | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment