class Contentful::Management::Locale
Public Class Methods
Source
# File lib/contentful/management/locale.rb, line 25 def self.create_attributes(_client, attributes) { 'name' => attributes.fetch(:name), 'code' => attributes.fetch(:code), 'optional' => attributes.fetch(:optional, false), 'fallbackCode' => attributes.fetch(:fallback_code, nil) } end
@private
Protected Instance Methods
Source
# File lib/contentful/management/locale.rb, line 36 def query_attributes(attributes) { name: name, code: code, optional: optional, fallbackCode: fallback_code }.merge( attributes.transform_keys(&:to_sym) ) end