5f64fd0a21
DEV: remove exec_sql and replace with mini_sql
...
Introduce new patterns for direct sql that are safe and fast.
MiniSql is not prone to memory bloat that can happen with direct PG usage.
It also has an extremely fast materializer and very a convenient API
- DB.exec(sql, *params) => runs sql returns row count
- DB.query(sql, *params) => runs sql returns usable objects (not a hash)
- DB.query_hash(sql, *params) => runs sql returns an array of hashes
- DB.query_single(sql, *params) => runs sql and returns a flat one dimensional array
- DB.build(sql) => returns a sql builder
See more at: https://github.com/discourse/mini_sql
2018-06-19 16:13:36 +10:00
f988fa31aa
FIX: ensure 'notifications_state' is up to date after creating a notification
2018-05-26 02:09:48 +02:00
9d307a9977
FIX: Destroy notifications and sync notifications count in transaction.
...
* Seeing errors where the user is destroyed right when the call to
reload is made.
2018-05-25 12:01:36 +08:00
755b511b5c
PERF: Destroy collapsed notifications in 1 query instead of 3.
2018-05-25 12:01:36 +08:00
bb8f0087f4
Add a warning when PostAlerter isn't running in sidekiq
2018-05-24 17:52:59 +02:00
71f66cd679
FIX: ensure PostAlerter is always run in sidekiq
2018-05-24 17:27:43 +02:00
2aad91d4a2
PERF: Don't bloat the Sidekiq queue with Jobs::SendPushNotification
.
2018-05-24 10:04:09 +08:00
be49da9105
FIX: Don't silently fail if notification fails to create.
2018-05-24 10:04:09 +08:00
147ea37115
FIX: Missing notification for watching first post users when topic is recategorized.
...
https://meta.discourse.org/t/not-receiving-notifications-for-announcements/87275/2?u=tgxworld
2018-05-17 16:15:29 +08:00
93ed8d2522
PERF: defer user notifications ( #5827 )
2018-05-15 09:51:32 +02:00
fc4fde453d
PERF: Remove N+1 query.
2018-05-07 18:21:48 +08:00
3d99726981
FIX: set notification level when changing post owner ( #5616 )
...
FIX: do not notify last post editor if they mention themself
2018-04-16 11:48:06 +02:00
f042a9529b
FIX: users shouldn't get notifications about mentions from system users
...
(unless the mentioned users are participants in a PM with the system user)
2018-04-12 16:19:44 +02:00
142571bba0
Remove use of rescue nil
.
...
* `rescue nil` is a really bad pattern to use in our code base.
We should rescue errors that we expect the code to throw and
not rescue everything because we're unsure of what errors the
code would throw. This would reduce the amount of pain we face
when debugging why something isn't working as expexted. I've
been bitten countless of times by errors being swallowed as a
result during debugging sessions.
2018-04-02 13:52:51 +08:00
dc77cce8d9
FIX: Create notifications for mentions in PMs
2018-03-09 11:04:29 +01:00
060e78e884
PERF: reduce memory usage for post alerter
2018-01-22 17:11:52 +11:00
d47fa6653b
do not notify staged users about posts withing mailinglist mirror category
2017-11-17 15:29:14 +01:00
31e2385316
FEATURE: do not send notification emails to users who are included in the To and CC header of an incoming email
2017-11-10 17:44:20 +01:00
3bdd8f57c1
FIX: invited staged users would sometimes not get notified of replies
2017-10-06 16:37:28 +02:00
4e5e7dc736
FIX: Fix ActiveRecord API that was removed in Rails 5.1.
2017-09-25 16:16:37 +08:00
23b787e0a6
Require dependency otherwise it causes Sidekiq to lock up in development.
2017-09-25 13:48:59 +08:00
87b4246c14
FIX: notify about whispered reply
2017-09-19 15:51:10 +02:00
5012d46cbd
Add rubocop to our build. ( #5004 )
2017-07-28 10:20:09 +09:00
ddc0134b48
add DiscourseEvent triggers necessary to update a user's permissions before they're notified
2017-07-21 11:03:54 -04:00
e888369f51
UX: Don't send emails for discobot notifications.
2017-06-12 17:00:27 +09:00
a7e65d98a9
FIX: mutex to avoid race condition with double notify
2017-05-26 17:04:40 -04:00
5943543ec3
FIX: Improve checks for non-human users.
2017-04-06 11:29:34 +08:00
cd39049262
SECURITY: do not send push notifications to suspended users
2017-04-05 08:28:24 -04:00
2f6a4cc6de
remove UserActionObserver, replace with after_save and service
...
interestingly there was some left over dead code from when stars
existed in the topic_users table
2016-12-22 16:46:53 +11:00
aaf947356b
correct regression where notifications scope is not pushing to push server
2016-10-14 22:52:39 +11:00
f4f5524190
FEATURE: user API now contains scopes so permission is granular
...
previously we supported blanket read and write for user API, this
change amends it so we can define more limited scopes. A scope only
covers a few routes. You can not grant access to part of the site and
leave a large amount of the information hidden to API consumer.
2016-10-14 16:05:42 +11:00
89daa43754
FEATURE: remap emojis back for push notifications and desktop alerts
2016-10-11 13:03:48 +11:00
4fe52c8cbe
FEATURE: backend support for pushing notifications to clients
2016-08-26 12:47:10 +10:00
c279889191
FIX: Watching First Post in groups was working incorrectly
2016-07-21 15:05:10 -04:00
09be741820
FIX: Don't alert on new posts in a topic unless it's a new record
2016-07-19 15:57:05 -04:00
4161ee210a
FEATURE: improved tag and category watching and tracking
...
- present tags watched on the user prefs page
- automatically watch or unwatch old topics based on watch status
New watching and tracking logic takes care of handling old topics
(either with or without read state)
When you watch a topic you now watch historically
Also removes confusing warnings from user.
2016-07-08 12:58:30 +10:00
2005565c9c
Server side code for Watching First Post Only
2016-07-07 11:21:50 -04:00
9fc0b8607c
Add event trigger for post notification alert.
2016-07-01 00:12:07 +08:00
f9e5c49350
FIX: blue notification instead of green for replies/mentions in PMs
2016-03-22 14:28:14 +11:00
091e7ef3ca
FIX: when a post is edited by someone other than the original author and a mention is added, the mention notification is from the person who edited
2016-03-08 15:26:12 -05:00
74e4251aff
FIX: collapse 'replied', 'quoted' and 'posted' to the same notification
2016-03-07 21:56:33 +01:00
af577a5854
FEATURE: like notification frequency of never
2016-03-06 09:12:59 +11:00
8b1772ac0f
FIX: if user undos like, and relikes notify
...
FEATURE: roll up likes for notify on all likes
2016-03-04 22:56:27 +11:00
5a6c34fb8a
regression, unable to edit posts
2016-03-03 16:00:14 +11:00
5f4075a6cf
FEATURE: users can select how frequently they are notified on likes
...
- first time
- first time and daily (default)
- always
2016-03-02 23:16:52 +11:00
e7cfbfeabb
FIX: Array#first
with block will return the first element if nothing matches.
2016-02-24 22:34:40 +08:00
8d1da9cedd
FEATURE: keep original title when sending email notifications about a PM
2016-02-23 01:34:16 +01:00
12051f79a8
FIX: don't send empty email notifications for small_actions
2016-02-01 19:12:10 +01:00
5ed21e8767
filter out archived correctly
2016-01-28 00:14:26 +11:00
b75353c26f
correct specs
2016-01-27 23:40:45 +11:00