diff options
author | Elias Nahum <nahumhbl@gmail.com> | 2016-03-11 00:14:55 -0300 |
---|---|---|
committer | Elias Nahum <nahumhbl@gmail.com> | 2016-03-17 13:20:17 -0300 |
commit | 1f5c8c4e4ebb2e163278f3e62d640f41a2df7294 (patch) | |
tree | a659674c9980e23752fc8d9f07eb48014c8bce26 /model/config.go | |
parent | d383ed2f8dfc320c090b67d9f2e2d111710ca3cf (diff) | |
download | chat-1f5c8c4e4ebb2e163278f3e62d640f41a2df7294.tar.gz chat-1f5c8c4e4ebb2e163278f3e62d640f41a2df7294.tar.bz2 chat-1f5c8c4e4ebb2e163278f3e62d640f41a2df7294.zip |
Option to enable full snippets in push notifications
Diffstat (limited to 'model/config.go')
-rw-r--r-- | model/config.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/model/config.go b/model/config.go index 11ce260ee..d684c72b2 100644 --- a/model/config.go +++ b/model/config.go @@ -25,6 +25,9 @@ const ( WEBSERVER_MODE_REGULAR = "regular" WEBSERVER_MODE_GZIP = "gzip" WEBSERVER_MODE_DISABLED = "disabled" + + GENERIC_NOTIFICATION = "generic" + FULL_NOTIFICATION = "full" ) type ServiceSettings struct { @@ -121,6 +124,7 @@ type EmailSettings struct { PasswordResetSalt string SendPushNotifications *bool PushNotificationServer *string + PushNotificationContents *string } type RateLimitSettings struct { @@ -299,6 +303,11 @@ func (o *Config) SetDefaults() { *o.EmailSettings.PushNotificationServer = "" } + if o.EmailSettings.PushNotificationContents == nil { + o.EmailSettings.PushNotificationContents = new(string) + *o.EmailSettings.PushNotificationContents = GENERIC_NOTIFICATION + } + if o.SupportSettings.TermsOfServiceLink == nil { o.SupportSettings.TermsOfServiceLink = new(string) *o.SupportSettings.TermsOfServiceLink = "/static/help/terms.html" |