discourse/app/assets/javascripts
Martin Brennan b2acc416e7
FIX: Server-side hashtag lookups of secure categories for a user (#19377)
* FIX: Use Category.secured(guardian) for hashtag datasource

Follow up to comments in #19219, changing the category
hashtag datasource to use Category.secured(guardian) instead
of Site.new(guardian).categories here since the latter does
more work for not much benefit, and the query time is the
same. Also eliminates some Hash -> Model back and forth
busywork. Add some more specs too.

* FIX: Server-side hashtag lookup cooking user loading

When we were using the PrettyText.options.currentUser
and parsing back and forth with JSON for the hashtag
lookups server-side, we had a bug where the user's
secure categories were not loaded since we never actually
loaded a User model from the database, only parsed it
from JSON.

This commit fixes the issue by instead using the
PretyText.options.userId and looking up the user directly
from the database when calling hashtag_lookup via the
PrettyText::Helpers code when cooking server-side. Added
the missing spec to check for this as well.
2022-12-09 10:34:25 +10:00
..
admin FIX: Show last match time of screened IP address (#19382) 2022-12-08 19:45:55 +02:00
bootstrap-json DEV: Fix multiple set-cookie through Ember-CLI proxy (#19316) 2022-12-05 15:01:55 +00:00
confirm-new-email DEV: Update linting setup and fix issues (#17345) 2022-07-06 10:37:54 +02:00
dialog-holder FEATURE: better UI to manage 2fa (#19338) 2022-12-08 09:41:22 +11:00
discourse FEATURE: Allow category moderators to set auto deletion topic timers (#19383) 2022-12-08 17:14:43 -03:00
discourse-common Build(deps-dev): Bump @embroider/test-setup in /app/assets/javascripts (#19272) 2022-11-30 22:56:25 +01:00
discourse-ensure-deprecation-order DEV: Silence 3.x deprecations 2022-07-19 10:00:59 +01:00
discourse-hbr Build(deps-dev): Bump @embroider/test-setup in /app/assets/javascripts (#19272) 2022-11-30 22:56:25 +01:00
discourse-plugins DEV: Support colocation under /admin namespace in themes/plugins (#19353) 2022-12-07 14:24:03 +00:00
discourse-widget-hbs Build(deps-dev): Bump @embroider/test-setup in /app/assets/javascripts (#19272) 2022-11-30 22:56:25 +01:00
docs DEV: enforces eslint’s curly rule to the codebase (#10720) 2020-09-22 16:28:28 +02:00
ember-addons DEV: Remove ember-addons (#9559) 2020-04-28 10:14:49 -04:00
ember-cli-progress-ci DEV: Add progress output in CI during ember-cli build (#17977) 2022-08-17 22:39:52 +01:00
locales FEATURE: Add Croatian language (#17130) 2022-06-18 00:18:22 +02:00
pretty-text FIX: Server-side hashtag lookups of secure categories for a user (#19377) 2022-12-09 10:34:25 +10:00
select-kit DEV: Remove user options from current user serializer (#19089) 2022-12-05 18:25:30 +02:00
truth-helpers Build(deps-dev): Bump @embroider/test-setup in /app/assets/javascripts (#19272) 2022-11-30 22:56:25 +01:00
wizard Build(deps-dev): Bump @embroider/test-setup in /app/assets/javascripts (#19272) 2022-11-30 22:56:25 +01:00
.licensee.json DEV: Have licensee check xmldom license (#18840) 2022-11-02 11:51:11 -04:00
.npmrc DEV: Prevent npm usage (#13945) 2021-08-04 22:04:58 +02:00
discourse-js-processor.js DEV: Introduce minification and source maps for Theme JS (#18646) 2022-10-18 18:20:10 +01:00
handlebars-shim.js FIX: It seems sometimes shims are evaluated by older JS engines (#11813) 2021-01-22 10:41:01 -05:00
package.json DEV: Make dialog-holder a monorepo package (#19051) 2022-11-16 16:43:45 +01:00
polyfills.js DEV: Add polyfill for String.prototype.replaceAll (#16301) 2022-03-28 17:18:56 +01:00
service-worker.js.erb FEATURE: Replyable chat push notifications (#18973) 2022-11-11 12:30:21 -03:00
yarn.lock Build(deps): Bump decode-uri-component in /app/assets/javascripts (#19311) 2022-12-05 12:39:50 +01:00