Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Register
Sign in
Toggle navigation
Menu
Open sidebar
Tiger Ton
mastodon
Commits
886ef1cc
Commit
886ef1cc
authored
6 years ago
by
ThibG
Committed by
Eugen Rochko
6 years ago
Browse files
Options
Download
Email Patches
Plain Diff
Fix emoji update date processing (#9255)
parent
d06a724b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
app/lib/activitypub/activity/create.rb
+1
-1
app/lib/activitypub/activity/create.rb
app/services/activitypub/process_account_service.rb
+1
-1
app/services/activitypub/process_account_service.rb
with
2 additions
and
2 deletions
+2
-2
app/lib/activitypub/activity/create.rb
+
1
-
1
View file @
886ef1cc
...
...
@@ -177,7 +177,7 @@ class ActivityPub::Activity::Create < ActivityPub::Activity
updated
=
tag
[
'updated'
]
emoji
=
CustomEmoji
.
find_by
(
shortcode:
shortcode
,
domain:
@account
.
domain
)
return
unless
emoji
.
nil?
||
image_url
!=
emoji
.
image_remote_url
||
(
updated
&&
emoji
.
updated_at
>=
updated
)
return
unless
emoji
.
nil?
||
image_url
!=
emoji
.
image_remote_url
||
(
updated
&&
updated
>=
emoji
.
updated_at
)
emoji
||=
CustomEmoji
.
new
(
domain:
@account
.
domain
,
shortcode:
shortcode
,
uri:
uri
)
emoji
.
image_remote_url
=
image_url
...
...
This diff is collapsed.
Click to expand it.
app/services/activitypub/process_account_service.rb
+
1
-
1
View file @
886ef1cc
...
...
@@ -232,7 +232,7 @@ class ActivityPub::ProcessAccountService < BaseService
updated
=
tag
[
'updated'
]
emoji
=
CustomEmoji
.
find_by
(
shortcode:
shortcode
,
domain:
@account
.
domain
)
return
unless
emoji
.
nil?
||
image_url
!=
emoji
.
image_remote_url
||
(
updated
&&
emoji
.
updated_at
>=
updated
)
return
unless
emoji
.
nil?
||
image_url
!=
emoji
.
image_remote_url
||
(
updated
&&
updated
>=
emoji
.
updated_at
)
emoji
||=
CustomEmoji
.
new
(
domain:
@account
.
domain
,
shortcode:
shortcode
,
uri:
uri
)
emoji
.
image_remote_url
=
image_url
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets