Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
FIX: Bug in setting notification level when the post was moved #9237
…ne topic into another. When the post was moved from one topic into a new one, and the user with `Automatically track topics I enter` preferences, visits that topic for the first time notification_level was not modified.
I changed that flow a little bit:
@SamSaffron - could you take another look? What do you think?
I am still super defensive of queries here cause this happens every time you visit a topic.
The change means we load the topic, then update it.
Previous implementation was that we update it... if update fails we create
So at a minimum it is 2 queries now and you pull a full model down.
I prefer that it just updates, if update fails, do a create cause usually you are updating cause you tend to visit topics twice or more.