File tree 2 files changed +9
-4
lines changed
app/controllers/lit/api/v1
2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 9
9
- gemfiles/rails_5.1.gemfile
10
10
- gemfiles/rails_5.2.gemfile
11
11
services :
12
- - redis-server
12
+ - postgresql
13
+ - redis-server
13
14
env :
14
15
- LIT_STORAGE=hash
15
16
- LIT_STORAGE=redis
@@ -18,4 +19,3 @@ before_script:
18
19
- psql -c 'create database lit_test;' -U postgres
19
20
- RAILS_ENV=test bundle exec rake db:migrate
20
21
script : " bundle exec rake test"
21
-
Original file line number Diff line number Diff line change @@ -22,12 +22,17 @@ def last_change
22
22
private
23
23
24
24
def fetch_localizations
25
+ scope = Localization . includes (
26
+ :locale ,
27
+ :localization_key
28
+ )
29
+
25
30
if params [ :after ] . present?
26
31
after_date = Time . parse ( "#{ params [ :after ] } #{ Time . zone . name } " )
27
32
. in_time_zone
28
- Localization . after ( after_date ) . to_a
33
+ scope . after ( after_date ) . to_a
29
34
else
30
- Localization . all
35
+ scope . all
31
36
end
32
37
end
33
38
end
You can’t perform that action at this time.
0 commit comments