Commit Graph

30671 Commits

Author SHA1 Message Date
4831c4c2ee FIX: Use safe navigation operator throughout statement 2018-12-03 20:00:28 +00:00
e32cdb00cb Fix the build 2018-12-03 18:51:07 +00:00
b373ff47e2 FIX: Topic is nil when first post is being created 2018-12-03 18:30:52 +00:00
4e2cc9caf0 FIX: Use safe navigation operator when looking for avatar URL 2018-12-03 17:28:21 +00:00
404acef6e3 DEV: Move run-qunit.js out of the vendor directory 2018-12-03 16:16:37 +00:00
923692d45a FIX: tooltip regression in admin dashboard
- adds registerHoverTooltip in tooltip qunit test
2018-12-03 11:15:31 -05:00
1a4676c6e0 FIX: Fixed tests. (#6716) 2018-12-03 17:03:11 +01:00
f8e6a37858 FIX: raise exception when getting dimensions of missing image
- follow-up on 0eacd45ab15cbd20ed9f444fd447886a7fc6dccb
2018-12-03 10:19:49 -05:00
9125b5fbc4 DEV: Reformat single line method definition
Following comments on 71aaed272c
2018-12-03 15:03:00 +00:00
3f8fa4ad4e FEATURE: Do not check consecutive replies for original poster. (#6714) 2018-12-03 02:32:29 -08:00
142361d6da FIX: don't steal focus when text in editor is replaced (#6712) 2018-12-03 09:49:17 +01:00
503ae1829f FIX: All multisite upload paths should start with /uploads/default/.. (#6707) 2018-12-03 12:04:14 +08:00
6121d11187 FIX: make staff_edit_locks_post work with download_remote_images_to_local 2018-12-03 14:14:59 +11:00
125bb46052 Remove unused constant in the codebase. 2018-12-03 11:04:47 +08:00
Sam
12f5889c85 DEV: stop logging warning when overriding open scope
ActiveRecord defines automatic scopes for enums, the Poll model defines
an enum for `{open: 1}` this mean Rails wants the scope `Poll.all.open`
to work which in turn means it has to override `open` which is defined
privately.

Rails feature req exists for: https://github.com/rails/rails/issues/34599
which will allow us to define enums without scopes which would resolve this
a lot more cleaner.
2018-12-03 13:52:09 +11:00
Sam
f555582eb2 DEV: add extra diagnostics for intermittent test fail 2018-12-03 11:46:31 +11:00
f94c3aef7b DEV: upgrades highlight.js from v9.12.0 to v9.13.1 2018-12-03 09:45:52 +11:00
1073634271 FIX: show generic title when quoting off-topic secure category posts 2018-12-03 09:42:32 +11:00
Sam
cc04c86859 UX: do not restrict width of category image, only height
This was a recent visual regression which caused a fair amount of pain.
Previously we only restricted height
2018-12-03 09:35:16 +11:00
Sam
236c755d62 FIX: do not store key tracking last seen time indefinitely
UserStat has some special logic to keep adding time read if repeat calls
are made in intervals less than 100 seconds. This is called regularly
when we update read timings on a topic.

We only need to cache this key in redis for 100 seconds, however previously
we would keep it forever, 1 key per user. This has potential of bloating
a very large amount of keys for no longer active users in redis.
2018-12-03 08:35:26 +11:00
26e9b628b8 post-infos alignment fix 2018-11-30 21:31:36 -05:00
7efc1b7bf7 Removing added text from commit a113777 2018-11-30 19:56:10 -05:00
a113777003 Extra margin isn't needed on mobile 2018-11-30 19:49:26 -05:00
71aaed272c DEV: Correct auth_provider deprecation warning 2018-11-30 22:22:26 +00:00
bbd33de05b FIX: lightbox expand icon on mobile 2018-11-30 14:35:45 -05:00
4e010382cc REFACTOR: Initialize auth providers after plugin.activate!
Also added some helpful functionality for plugin developers:
- Raises RuntimeException if the auth provider has been registered too late
- Logs use of deprecated parameters
2018-11-30 16:58:18 +00:00
488fba3c5f FEATURE: allow plugins and themes to extend the default CSP (#6704)
* FEATURE: allow plugins and themes to extend the default CSP

For plugins:

```
extend_content_security_policy(
  script_src: ['https://domain.com/script.js', 'https://your-cdn.com/'],
  style_src: ['https://domain.com/style.css']
)
```

For themes and components:

```
extend_content_security_policy:
  type: list
  default: "script_src:https://domain.com/|style_src:https://domain.com"
```

* clear CSP base url before each test

we have a test that stubs `Rails.env.development?` to true

* Only allow extending directives that core includes, for now
2018-11-30 09:51:45 -05:00
7dec963f2e FIX: add vkontakte icon alias 2018-11-30 08:50:38 -05:00
208005f9c9 REFACTOR: Migrate FacebookAuthenticator to use ManagedAuthenticator
Changes to functionality
  - Removed syncing of user metadata including gender, location etc.
    These are no longer available to standard Facebook applications.
  - Removed the remote 'revoke' functionality. No other providers have
    it, and it does not appear to be standard practice in other apps.
  - The 'facebook_no_email' event is no longer logged. The system can
    cope fine with a missing email address.

Data is migrated to the new user_associated_accounts table.
facebook_user_infos can be dropped once we are confident the data has
been migrated successfully.
2018-11-30 11:18:11 +00:00
534e1b1b18 DEV: Introduce Auth::ManagedAuthenticator
A generic implementation of Auth::Authenticator which stores data in the
new UserAssociatedAccount model. This should help significantly reduce the duplicated
logic across different auth providers.
2018-11-30 11:18:11 +00:00
059e36a6ff FIX: log name changes only when the name is actually updated 2018-11-30 15:30:46 +05:30
fc0b7c9e26 FIX: incoming email matches the wrong user if null bounce key available in db 2018-11-30 12:29:51 +05:30
Sam
c6adf7f032 DEV: correct heisentest
After you visit a page in Rails an INFO is logged, this depending on
timing could land in the string or not

This changes the level to WARN which avoids the issue
2018-11-30 15:03:41 +11:00
Sam
8868cfd2e4 FIX: redis leak when visiting large amounts of topics
Message bus uses a key to keep track of the last id for each channel
this key was never expired even if channel data expired

This change ensures we also expire the tracking key, it means a lot to us
cause each topic has a channel, so if you have 1 million topics that is
1 million keys that may persist forever
2018-11-30 14:41:15 +11:00
df2d02a7bc Revert "Enable Style/BlockDelimiters rule."
This reverts commit 3c22fb6b7034df7f9bd5adf0b07c781d694fcbcf.
2018-11-30 10:59:45 +08:00
eecd1a7d8c FIX: Jobs::CleanUpUploads fails when value of upload data_type is an empty string. 2018-11-30 10:46:39 +08:00
3c22fb6b70 Enable Style/BlockDelimiters rule. 2018-11-30 10:18:15 +08:00
ad665b901a FIX: Refactor commit a8c3ca, add test 2018-11-29 19:12:00 -05:00
a58c3ca430 FIX: limit SvgSprite scan to string setting values 2018-11-29 18:36:48 -05:00
0eacd45ab1 FIX: refactor ImageSizer.resize
reverts 140d9c2
2018-11-29 15:28:45 -05:00
140d9c2910 FIX: call ImageSizer only if width/height are available 2018-11-29 15:03:02 -05:00
40f10855c6 FIX: defer flags (only) when handling a flag and deleting replies (#6702) 2018-11-29 22:44:18 +05:30
4a8f21d387 FIX: prevent minimum_required_tags on category being set to null (#6703)
* FIX: prevent minimum_required_tags on category being set to null

* add migration for NOT_NULL constraint for minimum_required_tags

* add specs
2018-11-29 18:10:14 +01:00
5b6c1b1670 SCSS refactoring
followup on c388cac
2018-11-29 12:02:11 -05:00
075d9fc558 Version bump to v2.2.0.beta5 v2.2.0.beta5 2018-11-29 11:18:11 -05:00
d43d007929 Update translations 2018-11-29 10:51:16 -05:00
4f24d7dec8 FIX: more resilient whisper state between composer states (#6687) 2018-11-29 16:16:34 +01:00
8da8f5d0f7 FIX: call onSelect plugin callbacks for noop rows (#6682) 2018-11-29 15:56:19 +01:00
6b433b66f5 FIX: always prepend watching user timezone to previews (#6695) 2018-11-29 12:02:27 +01:00
4c7dfed32e FIX: error with tags enabled and no tags created (#6701) 2018-11-29 10:39:09 +01:00