mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-09-15 01:24:53 +08:00
Merge pull request #1669 from okriuchykhin/ok_SCI_3340
Fix crash when no activities present [SCI-3340]
This commit is contained in:
commit
a61d637e6d
2 changed files with 2 additions and 2 deletions
|
@ -49,7 +49,7 @@ class GlobalActivitiesController < ApplicationController
|
|||
end
|
||||
|
||||
@next_page = activities.next_page
|
||||
@starting_timestamp = activities.first.created_at.to_i
|
||||
@starting_timestamp = activities.first&.created_at.to_i
|
||||
|
||||
respond_to do |format|
|
||||
format.json do
|
||||
|
|
|
@ -90,7 +90,7 @@ class MyModulesController < ApplicationController
|
|||
end
|
||||
|
||||
@next_page = activities.next_page
|
||||
@starting_timestamp = activities.first.created_at.to_i
|
||||
@starting_timestamp = activities.first&.created_at.to_i
|
||||
|
||||
respond_to do |format|
|
||||
format.json do
|
||||
|
|
Loading…
Add table
Reference in a new issue