Skip to content

Commit

Permalink
FIX: Remove settings lookup and adjust show_in_options_dropdown logic
Browse files Browse the repository at this point in the history
  • Loading branch information
Arkshine committed Jan 8, 2024
1 parent d103b22 commit 942d126
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions javascripts/discourse/initializers/insert-jitsi.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,9 @@ export default {
withPluginApi("0.8.31", (api) => {
const currentUser = api.getCurrentUser();
const modal = api.container.lookup("service:modal");
const settings = api.container.lookup("site-settings:main");

if (settings.show_in_options_dropdown) {

Check failure on line 78 in javascripts/discourse/initializers/insert-jitsi.js

View workflow job for this annotation

GitHub Actions / ci / linting

'settings' is not defined
if (settings.only_available_to_staff && currentUser?.staff) {
if (!settings.only_available_to_staff || currentUser?.staff) {

Check failure on line 79 in javascripts/discourse/initializers/insert-jitsi.js

View workflow job for this annotation

GitHub Actions / ci / linting

'settings' is not defined
api.addComposerToolbarPopupMenuOption({
icon: settings.button_icon,

Check failure on line 81 in javascripts/discourse/initializers/insert-jitsi.js

View workflow job for this annotation

GitHub Actions / ci / linting

'settings' is not defined
label: themePrefix("composer_title"),

Check failure on line 82 in javascripts/discourse/initializers/insert-jitsi.js

View workflow job for this annotation

GitHub Actions / ci / linting

'themePrefix' is not defined
Expand Down

0 comments on commit 942d126

Please sign in to comment.