rhymes
5a2cae4fbb
Rubocop: enable and fix new Rails cops ( #9537 )
...
* Enable new Rails/* cops and use autocorrect on them
* Fixed Rails/PluckInWhere leftovers
* Fix Rails/DefaultScope
* Enable and fix Rails/PluckId
* Fix manual mistake with forcing autocorrection on Rails/PluckId
* Apply PR feedback to remove Rails/PluckId inline disables
* Apply PR feedback to get rid of Rails/PluckInWhere inline
2020-07-29 11:14:19 +02:00
rhymes
f1ec04a0c9
Rubocop: move dot in multi-line calls to leading position ( #9262 )
2020-07-16 15:51:11 +02:00
Ben Halpern
da6a6739e5
[deploy] Invite users to join and create password ( #9294 )
...
* Initial invitation work
* Add more invitation code
* Add proper registration page
* Fix up tests
* Fix failings
* Fix spec
* Add self-serve auth config
* Add registered condition
* Change profile image call and registered_at test
* Change comment
* Fix copy test
* Stub emojipedia
* Linting
* Add registered at to factory
* Ensure registered for user tag
* Update app/views/internal/invitations/index.html.erb
Co-authored-by: Michael Kohl <citizen428@dev.to>
* Update app/controllers/internal/invitations_controller.rb
Co-authored-by: Michael Kohl <citizen428@dev.to>
* Slight changes
* Update recover password flow
* Update app/views/internal/invitations/index.html.erb
Co-authored-by: Michael Kohl <citizen428@dev.to>
* Update app/controllers/internal/invitations_controller.rb
Co-authored-by: Michael Kohl <citizen428@dev.to>
* Update db/schema.rb
Co-authored-by: Michael Kohl <citizen428@dev.to>
2020-07-15 11:37:19 -04:00
rhymes
5b62811c98
[deploy] Rubocop: fix violations of Layout/LineLength ( #9197 )
2020-07-08 08:36:36 -05:00
Dmitry Maksyoma
17a9335680
Duplicate notifications, when replying to and mentioning the same user ( #8156 )
...
* Refactor Mentions::CreateAll
* Update app/services/mentions/create_all.rb
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
* Refactor for readability
* Try writing tests for duplicate notifications
* Skip Bullet warning, essentially for #current_user
* Fix duplicate notification, when mentioning comment author
* Improve spec readability
* Refactor specs and fix duplicate notificaation for moderator comments
* Refactor spec
* Remove obsolete code and refactor specs
* Remove obsolete spec
* Update spec/requests/comments_create_spec.rb
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
* Get rid of #json_response
* Remove Bullet skipping
* Change #where -> #exists?
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
2020-06-17 08:47:31 -04:00
Dmitry Maksyoma
eb85a91a9d
Refactor Mentions::CreateAll ( #7880 )
...
* Refactor Mentions::CreateAll
* Update app/services/mentions/create_all.rb
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
* Refactor for readability
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
2020-05-21 12:08:36 +02:00
aRtoo
05cfe16e1c
Fix comment author being notified when mentioning itself ( #4456 )
...
* added a condition to check if owner of the comment is in mentions
* added a test to check if comment owner can mention self
* fixed metion test by:
- adding a second user to simulate a owner of a comment
- change the user on comment to owned by newly created user
2019-10-25 10:23:45 -04:00
Andy Zhao
3b0f6f2834
Refactor remove_all and remove_each notifications and fix orphaned notifications ( #3570 )
2019-09-25 15:31:56 -04:00
rhymes
c42c28ae59
Performance: save some queries when pluck is not needed ( #3160 )
2019-06-14 14:56:33 -04:00
Kartikey Tanna
858ce184e5
Implement ActiveJob for Mention ( #3055 )
...
* Implemented ActiveJob for Mention#send_email_notification
* Implemented ActiveJob for Mention.create_all
* Fixed args while calling the job
* Changes as per the review
2019-06-13 11:05:22 -04:00