mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
25 lines
796 B
Diff
25 lines
796 B
Diff
--- /var/www/sharelatex/web/app/src/Features/User/UserCreator.js
|
|
+++ /var/www/sharelatex/web/app/src/Features/User/UserCreator.js
|
|
@@ -85,13 +85,15 @@ async function createNewUser(attributes, options = {}) {
|
|
}
|
|
|
|
Analytics.recordEvent(user._id, 'user-registered')
|
|
- try {
|
|
- await UserOnboardingEmailQueueManager.scheduleOnboardingEmail(user)
|
|
- } catch (error) {
|
|
- logger.error(
|
|
- `Failed to schedule sending of onboarding email for user '${user._id}'`,
|
|
- error
|
|
- )
|
|
+ if(Features.hasFeature('saas')) {
|
|
+ try {
|
|
+ await UserOnboardingEmailQueueManager.scheduleOnboardingEmail(user)
|
|
+ } catch (error) {
|
|
+ logger.error(
|
|
+ `Failed to schedule sending of onboarding email for user '${user._id}'`,
|
|
+ error
|
|
+ )
|
|
+ }
|
|
}
|
|
|
|
return user
|