Skip to content

Commit 115869b

Browse files
committed
remove changes on whitespaces
1 parent 4c856ef commit 115869b

2 files changed

Lines changed: 24 additions & 25 deletions

File tree

test/controllers/controller_test.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,6 @@ def test_on_server_error_method_callback_with_exception_on_serialize
140140
ensure
141141
$PostSerializerRaisesErrors = false
142142
JSONAPI.configuration = original_config
143-
JSONAPI.configuration.exception_class_whitelist = []
144143
end
145144

146145
def test_on_server_error_callback_without_exception

test/fixtures/active_record.rb

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -995,12 +995,12 @@ def title=(title)
995995
}
996996

997997
filter :search,
998-
verify: ->(values, context) {
998+
verify: ->(values, context) {
999999
values.all?{|v| (v.is_a?(Hash) || v.is_a?(ActionController::Parameters)) } && values
1000-
},
1001-
apply: -> (records, values, _options) {
1002-
records.where(title: values.first['title'])
1003-
}
1000+
},
1001+
apply: -> (records, values, _options) {
1002+
records.where(title: values.first['title'])
1003+
}
10041004

10051005
def self.updatable_fields(context)
10061006
super(context) - [:author, :subject]
@@ -1267,7 +1267,7 @@ def subject
12671267

12681268
def custom_links(options)
12691269
{
1270-
link_to_external_api: "http://external-api.com/posts/#{ created_at.year }/#{ created_at.month }/#{ created_at.day }-#{ subject.gsub(' ', '-') }"
1270+
link_to_external_api: "http://external-api.com/posts/#{ created_at.year }/#{ created_at.month }/#{ created_at.day }-#{ subject.gsub(' ', '-') }"
12711271
}
12721272
end
12731273
end
@@ -1528,28 +1528,28 @@ class PurchaseOrderResource < JSONAPI::Resource
15281528

15291529
has_one :customer
15301530
has_many :line_items, relation_name: -> (options = {}) {
1531-
context = options[:context]
1532-
current_user = context ? context[:current_user] : nil
1533-
1534-
unless current_user && current_user.book_admin
1535-
:line_items
1536-
else
1537-
:admin_line_items
1538-
end
1539-
},
1531+
context = options[:context]
1532+
current_user = context ? context[:current_user] : nil
1533+
1534+
unless current_user && current_user.book_admin
1535+
:line_items
1536+
else
1537+
:admin_line_items
1538+
end
1539+
},
15401540
reflect: false
15411541

15421542
has_many :order_flags, acts_as_set: true,
15431543
relation_name: -> (options = {}) {
1544-
context = options[:context]
1545-
current_user = context ? context[:current_user] : nil
1546-
1547-
unless current_user && current_user.book_admin
1548-
:order_flags
1549-
else
1550-
:admin_order_flags
1551-
end
1552-
}
1544+
context = options[:context]
1545+
current_user = context ? context[:current_user] : nil
1546+
1547+
unless current_user && current_user.book_admin
1548+
:order_flags
1549+
else
1550+
:admin_order_flags
1551+
end
1552+
}
15531553
end
15541554

15551555
class OrderFlagResource < JSONAPI::Resource

0 commit comments

Comments
 (0)