Skip to content

Commit

Permalink
feat(resources): improve usage of title and name attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
bethesque committed Sep 14, 2017
1 parent 3a9a178 commit 915a7ee
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 7 deletions.
3 changes: 1 addition & 2 deletions lib/pact_broker/api/decorators/pact_collection_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ def create_representable_pact pact
represented.collect do | pact |
{
:href => latest_pact_url(options[:base_url], pact),
:name => "Latest pact between #{pact.consumer.name} and #{pact.provider.name}",
:title => "Pact"
:title => "Latest pact between #{pact.consumer.name} and #{pact.provider.name}",
}
end
end
Expand Down
3 changes: 1 addition & 2 deletions lib/pact_broker/api/decorators/pact_versions_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ class PactVersionsDecorator < BaseDecorator
link :self do | context |
{
href: context[:resource_url],
title: "Pact versions",
name: "All versions of the pact between #{context[:consumer_name]} and #{context[:provider_name]}"
title: "All versions of the pact between #{context[:consumer_name]} and #{context[:provider_name]}"
}
end

Expand Down
2 changes: 0 additions & 2 deletions lib/pact_broker/api/decorators/webhook_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,7 @@ class WebhookDecorator < BaseDecorator
title: "Test the execution of the webhook by sending a POST request to this URL",
href: webhook_execution_url(represented, options[:base_url])
}

end

end
end
end
Expand Down
1 change: 0 additions & 1 deletion lib/pact_broker/api/decorators/webhooks_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ class WebhooksDecorator < BaseDecorator
templated: true
}]
end

end
end
end
Expand Down

0 comments on commit 915a7ee

Please sign in to comment.