Skip to content

Commit

Permalink
watch meteor settings without Meteor.startup
Browse files Browse the repository at this point in the history
  • Loading branch information
pierre-lehnen-rc committed Jan 2, 2024
1 parent 636f9da commit cc4ba82
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion apps/meteor/app/meteor-accounts-saml/server/startup.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Logger } from '@rocket.chat/logger';
import debounce from 'lodash.debounce';
import { Meteor } from 'meteor/meteor';

import { settings } from '../../settings/server';
Expand All @@ -10,5 +11,6 @@ SAMLUtils.setLoggerInstance(logger);

Meteor.startup(async () => {
await addSettings('Default');
settings.watchByRegex(/^SAML_.+/, loadSamlServiceProviders);
});

settings.watchByRegex(/^SAML_.+/, debounce(loadSamlServiceProviders, 2000));

0 comments on commit cc4ba82

Please sign in to comment.