mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 18:30:26 -06:00
Revert "REFACTOR: remove unnecessary parentheses attempt 2 (follow-up on 154f503d
)"
This reverts commit 7db2dc717e
.
Commit breaks post edits for regular users.
This commit is contained in:
parent
1c6a2262b3
commit
d2a7f29595
@ -215,7 +215,8 @@ class Post < ActiveRecord::Base
|
||||
end
|
||||
|
||||
def matches_recent_post?
|
||||
$redis.get(unique_post_key)&.to_i != id
|
||||
post_id = $redis.get(unique_post_key)
|
||||
post_id != (nil) && post_id.to_i != (id)
|
||||
end
|
||||
|
||||
def raw_hash
|
||||
|
Loading…
Reference in New Issue
Block a user