Commit Graph

37896 Commits

Author SHA1 Message Date
Joffrey JAFFEUX 8fe074430b
REVERT: partly revert change to ensure context is the same (#10012) 2020-06-10 11:10:39 +02:00
Guo Xiang Tan a3dfd553a1
Revert "Bump redis to 4.2.0."
This reverts commit 98bc28cea2.
2020-06-10 14:52:05 +08:00
Guo Xiang Tan 98bc28cea2
Bump redis to 4.2.0. 2020-06-10 14:28:56 +08:00
Guo Xiang Tan 2ce829cc01
DEV: Allow multisite apps to boot with reading connection handler. 2020-06-10 14:18:29 +08:00
Sam Saffron 7589551d68
PERF: enable bootsnap globally
If people wish to opt out they can use `DISABLE_BOOTSNAP = 1`

Bootsnap is production ready and was tested on our production
servers for safety.

Promoting it now so it is enabled globally.

Will result in faster application boot
2020-06-10 12:20:17 +10:00
Jeff Atwood 7e1c93326f copyedit: make it more clear PMs are blocked by ignore and mute 2020-06-09 18:56:30 -07:00
Guo Xiang Tan 31a527a293
FIX: Return 400 when invalid topic_id is provided when creating invite. 2020-06-10 09:29:28 +08:00
Guo Xiang Tan 45fd668dc5
DEV: Render a proper response that can be handled on the client side. 2020-06-10 09:25:58 +08:00
Krzysztof Kotlarek f993d8a197
FIX: flaky post_alerter_spec.rb because of missing order (#10000) 2020-06-10 08:28:54 +10:00
Jeff Wong 70a88111dd
FIX: prevent re-flagging when we have reviewed flags before (#10010)
FIX: prevent re-flagging when we have reviewed flags before

Fixes an edge case where a review can be reflagged when:
User flags as inappropriate.
Moderator rejects the flag.
Another user re-flags the post as spam.

Before, anyone was able to re-flag as inappropriate despite it being flagged
previously. With this, users are unable to re-flag for the same reason
regardless of reviewable status.
2020-06-09 15:26:10 -07:00
David Taylor 9e98c02dd7
FIX: Don't call cooked decorators in composer if cooked is unchanged
If cooked is unchanged, ember will not re-render the preview area, so we should not re-run the post-processing decorators. This can cause issues when decorateCooked functions are not idempotent.
2020-06-09 23:01:07 +01:00
Vinoth Kannan f67e7d2fad FIX: add attributes of `params` to topic `findOpts`.
If `params` is ignored then `findTopicList` won't get the `no_subcategories` attribute.

d27b877a40
2020-06-10 01:33:58 +05:30
Joffrey JAFFEUX 43e17f92e0
DEV: allows to call a widget function without re-rendering the widget (#10004) 2020-06-09 19:58:17 +02:00
Joffrey JAFFEUX 84d767716f
linting (#10008) 2020-06-09 19:54:06 +02:00
David Taylor ae6c4cd237
FIX: Allow merging users when email domains are restricted 2020-06-09 18:51:59 +01:00
Joffrey JAFFEUX a3cf1cf6ff
DEV: allows to prepend widgets to post nav controls (#10005)
Co-authored-by: Régis Hanol <regis@hanol.fr>
2020-06-09 19:37:06 +02:00
Joffrey JAFFEUX 23ed16339f
DEV: adds mouse{Over,Out} and touch{Start,End} to widgets (#10003) 2020-06-09 19:36:28 +02:00
Joe 415c1bb9e1 FIX: don't show create topic suggestion to users who can't
Users with TL below the "min trust to create topic" setting used to see a prompt to create new topics in the footer message below the topic list. Those topics would never be submitted because those users don't meet the TL requirements to create a new topic (based on that site setting). This PR removes that prompt for those users.
2020-06-10 00:02:11 +08:00
Arpit Jalan 3094459cd9
FEATURE: multiple use invite links (#9813) 2020-06-09 20:49:32 +05:30
Gerhard Schlager 6b7a2d6d4d DEV: Remove non-existent option from setup-ruby Github action 2020-06-09 15:50:09 +02:00
David Taylor f1fc6cd40d
DEV: Add user-card-additional-buttons plugin outlet
The user-card-additional-controls outlet is outside the `<li>` element, which makes styling difficult. Placing an outlet inside the button list means that themes/plugins can easily reuse core styling.
2020-06-09 14:33:24 +01:00
Guo Xiang Tan edc940ce3e
DEV: Fix incorrect messagebus redis config for rails_failover. 2020-06-09 17:05:14 +08:00
Guo Xiang Tan c35649ccf1
DEV: Remove Redis noop logging.
When Redis drops into readonly mode, it floods the log. The log isn't
actionable and we have other means of knowing that an app is in readonly
mode.
2020-06-09 16:45:34 +08:00
Guo Xiang Tan a1c13eb3c6
DEV: Redis failover should only clear redis recently readonly. 2020-06-09 16:36:31 +08:00
Sam Saffron 716629dc0a
DEV: correct flaky test relying on possibly valid user id
This test lasted about 7 years prior to it becoming flaky.

Today ... for whatever reason the test suite created 100 users
prior to running this spec. So the new user becomes user id 101

And... lo and behold:

```

  1) PostSerializer a hidden post with add_raw enabled a hidden post shows the raw post only if authorized to see it
     Failure/Error: expect(serialized_post_for_user(Fabricate(:user))[:raw]).to eq(nil)

       expected: nil
            got: "Raw contents of the post."

       (compared using ==)
     # ./spec/serializers/post_serializer_spec.rb:127:in `block (4 levels) in <main>'
```
2020-06-09 17:40:41 +10:00
Sam Saffron 08044b4f94
FIX: emoji autocomplete triggering incorrectly
Previous to this fix the we were checking for non letters.

This was mismatching what pretty-text/addon/emoji.js was doing.

`ù:su`

and

`1:su`

Would lead to an emoji autocomplete popup in the composer.
2020-06-09 17:22:51 +10:00
Guo Xiang Tan 8b434531e4
Bump message_bus to 3.3.1. 2020-06-09 14:12:14 +08:00
Martin Brennan 3e210b76d9 FIX: Change bookmark name "name" attr to disable autocomplete 2020-06-09 14:47:30 +10:00
Kris d09bf892c7 UX: Improve layout of topic pin admin modal 2020-06-08 23:58:53 -04:00
Kane York 9b050f2822
FIX: Enforce maximum of 100 years on all site settings counted in days (#9991) 2020-06-09 12:48:51 +10:00
Guo Xiang Tan 4065cd198a
DEV: Print backtrace of error when plugin fails to initialize. 2020-06-09 10:25:43 +08:00
Penar Musaraj c5b1f028ed
FIX: update minimum required tag when switching categories in composer 2020-06-08 17:10:26 -04:00
Kris fbeaba4acf FIX: don't override category text color in dropdown 2020-06-08 16:45:30 -04:00
Penar Musaraj bdba17cdf7
FIX: Restore stream position in safari (#9993)
Safari uses an aggressive back/forward cache, which means the app loads
very quickly when hitting Back. But, in topics with > 30 posts, hitting
Back runs post stream calculations too early, which means that users
get taken back to an earlier point in the stream, consistently.

Using `onpageshow`, we can restore the correct location before the post
stream calculations take place.
2020-06-08 10:13:46 -04:00
Bianca Nenciu 052c91770f
FIX: Reply notifications should not appear as edited (#9965) 2020-06-08 15:23:33 +02:00
Joffrey JAFFEUX cb13152a43
FIX: ensures edit-category-setting is correctly casting boolean (#9999) 2020-06-08 15:16:42 +02:00
David Taylor 472862e87d
DEV: Do not attempt to change schema of posts table
Changing this requires rebuilding the badge_posts view, so will need to be done separately

Followup to f7d676dc
2020-06-08 13:52:31 +01:00
David Taylor 556380f970
DEV: Do not attempt to change schema badge_posts view
Followup to f7d676dc
2020-06-08 13:08:28 +01:00
David Taylor f7d676dce1
DEV: Correct historical schema discrepancies (#9955)
Rails schema defaults have changed over the years. This migration will correct discrepancies, and make all databases match the modern schema.
2020-06-08 12:20:27 +01:00
David Taylor 833b5d89e0
PERF: Cache PrettyText instance for rendering composer preview (#9987)
Previously we were building pretty-text from scratch on every keypress
2020-06-08 10:42:59 +01:00
Guo Xiang Tan 4ce618e55b
Bump rails_failover. 2020-06-08 17:04:58 +08:00
Gerhard Schlager 0bf753a739 DEV: Remove unused routes 2020-06-08 10:26:29 +02:00
Gerhard Schlager 8c6a42c589 FIX: Redirects containing Unicode usernames didn't work 2020-06-08 10:26:29 +02:00
Guo Xiang Tan f6628e4f43
DEV: Disable messageBus keepalive when Redis fails over. 2020-06-08 12:33:08 +08:00
Guo Xiang Tan 2ffda2b320
Bump rails_failover. 2020-06-08 12:19:33 +08:00
Guo Xiang Tan dc8b773765
Update rails_failover. 2020-06-08 11:03:25 +08:00
dependabot-preview[bot] cb015efb74 Bump rubocop from 0.85.0 to 0.85.1
Bumps [rubocop](https://github.com/rubocop-hq/rubocop) from 0.85.0 to 0.85.1.
- [Release notes](https://github.com/rubocop-hq/rubocop/releases)
- [Changelog](https://github.com/rubocop-hq/rubocop/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rubocop-hq/rubocop/compare/v0.85.0...v0.85.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-06-08 09:11:58 +08:00
Jeff Atwood dc49581344
clarify on supported Linux distros 2020-06-07 17:50:45 -07:00
David Taylor 293467a37a
REFACTOR: Remove jquery usage from resolveAllShortUrls, and fix debounce
- This function now requires an explicit scope. It will never run on the entire document.

- Previously debounce was being used with an anonymous function, which means it was having no effect.
2020-06-05 17:15:14 +01:00
Joffrey JAFFEUX d4caf69ed7
DEV: makes SKIP_INSTALL_PLUGINS called last and global (#9990) 2020-06-05 17:59:23 +02:00