Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

Commit

Permalink
remove hack code for GET /hardware_product/specification/latest
Browse files Browse the repository at this point in the history
..this should have been removed with commit 38e0ca3.
  • Loading branch information
karenetheridge committed Jan 19, 2021
1 parent 114be7c commit 973140d
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions lib/Conch/Controller/JSONSchema.pm
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,6 @@ sub get_from_disk ($c) {
$bundled_schema->{'$id'} = $c->url_for('/json_schema/'.$type.'/'.$name)->to_abs;
$bundled_schema->{'$schema'} //= 'https://json-schema.org/draft/2019-09/schema';

# hack! remove when adding get-from-database functionality
if ($c->req->url->path =~ qr{^/json_schema/hardware_product/specification/(?:1|latest)$}) {
$bundled_schema->{'$id'} = $c->url_for->path('1')->to_abs;
delete $bundled_schema->{deprecated};
}

$c->res->headers->content_type('application/schema+json');
return $c->status(200, $bundled_schema);
}
Expand Down

0 comments on commit 973140d

Please sign in to comment.