From 5a569093a3c353e2ddd3a7aee6e83471f2ea3f15 Mon Sep 17 00:00:00 2001 From: Josh Cohen Date: Sun, 13 Mar 2016 21:42:07 -0400 Subject: [PATCH] Don't use curies to expand resource links. Curies hrefs are for doc links. https://tools.ietf.org/html/draft-kelly-json-hal-07#section-8.2 --- lib/hyperclient/link_collection.rb | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lib/hyperclient/link_collection.rb b/lib/hyperclient/link_collection.rb index cf98d67..f1dc318 100644 --- a/lib/hyperclient/link_collection.rb +++ b/lib/hyperclient/link_collection.rb @@ -46,10 +46,6 @@ def build_link(name, link_or_links, curies, entry_point) link_or_links.map do |link| build_link(name, link, curies, entry_point) end - elsif (curie_parts = /(?[^:]+):(?.+)/.match(name)) - curie = curies[curie_parts[:ns]] - link_or_links['href'] = curie.expand(link_or_links['href']) if curie - Link.new(name, link_or_links, entry_point) else Link.new(name, link_or_links, entry_point) end