Sha256: 9d1696bb9ffe1bb015518921f10cd01fc835dc427985e93a711e6b162ed70bd4
Contents?: true
Size: 632 Bytes
Versions: 4
Compression:
Stored size: 632 Bytes
Contents
require "i18n" module Shamu module JsonApi # A generic error class for problems with shamu JSON API. class Error < Shamu::Error private def translation_scope super.dup.insert( 1, :json_api ) end end # Raised if an {ResourceBuilder#identifier} was not built. class IncompleteResourceError < Error def initialize( message = :incomplete_resource ) super end end class NoPresenter < Error def initialize( resource, namespaces ) super translate( :no_presenter, class: resource.class, namespaces: namespaces ) end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
shamu-0.0.9 | lib/shamu/json_api/error.rb |
shamu-0.0.8 | lib/shamu/json_api/error.rb |
shamu-0.0.7 | lib/shamu/json_api/error.rb |
shamu-0.0.5 | lib/shamu/json_api/error.rb |