diff options
author | multiple creatures <dev@multiple-creature.party> | 2019-08-06 13:55:54 -0500 |
---|---|---|
committer | multiple creatures <dev@multiple-creature.party> | 2019-08-06 13:55:54 -0500 |
commit | da389a664b87bb131435f2ccb904c0754d5d1655 (patch) | |
tree | 79f6fe6b29f2c361f1c33aa9a811991892b2f0db /app/models/status.rb | |
parent | 647ac0f86abb49b97c55229b70e9c06e943adc98 (diff) |
added ability to link accounts with `account:link:token` + `account:link:add` & switch between them with `i:am`/`we:are` bangtags; remove links with `account:link:del:USERNAME` or `account:link:clear`; list links with `account:link:list`
Diffstat (limited to 'app/models/status.rb')
-rw-r--r-- | app/models/status.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/app/models/status.rb b/app/models/status.rb index a6be93789..9f11e6d5d 100644 --- a/app/models/status.rb +++ b/app/models/status.rb @@ -306,6 +306,14 @@ class Status < ApplicationRecord update_status_stat!(key => [public_send(key) - 1, 0].max) end + def session=(value) + @session = value + end + + def session + @session || nil + end + after_create_commit :increment_counter_caches after_destroy_commit :decrement_counter_caches |