aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/account/user-notification-setting.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-08-30 16:50:12 +0200
committerChocobozzz <chocobozzz@cpy.re>2019-09-04 16:24:58 +0200
commit8424c4026afd7304880a4ce8138a04ffb3d8c938 (patch)
tree5b42625a59307b03333aa7d293b40b4c90da8f73 /server/models/account/user-notification-setting.ts
parentf69ec5f340638ef577e8f5b9b1fb844778656a1f (diff)
downloadPeerTube-8424c4026afd7304880a4ce8138a04ffb3d8c938.tar.gz
PeerTube-8424c4026afd7304880a4ce8138a04ffb3d8c938.tar.zst
PeerTube-8424c4026afd7304880a4ce8138a04ffb3d8c938.zip
Add auto follow back support for instances
Diffstat (limited to 'server/models/account/user-notification-setting.ts')
-rw-r--r--server/models/account/user-notification-setting.ts12
1 files changed, 11 insertions, 1 deletions
diff --git a/server/models/account/user-notification-setting.ts b/server/models/account/user-notification-setting.ts
index 1506295cf..dc69a17fd 100644
--- a/server/models/account/user-notification-setting.ts
+++ b/server/models/account/user-notification-setting.ts
@@ -114,6 +114,15 @@ export class UserNotificationSettingModel extends Model<UserNotificationSettingM
114 @AllowNull(false) 114 @AllowNull(false)
115 @Default(null) 115 @Default(null)
116 @Is( 116 @Is(
117 'UserNotificationSettingNewInstanceFollower',
118 value => throwIfNotValid(value, isUserNotificationSettingValid, 'autoInstanceFollowing')
119 )
120 @Column
121 autoInstanceFollowing: UserNotificationSettingValue
122
123 @AllowNull(false)
124 @Default(null)
125 @Is(
117 'UserNotificationSettingNewFollow', 126 'UserNotificationSettingNewFollow',
118 value => throwIfNotValid(value, isUserNotificationSettingValid, 'newFollow') 127 value => throwIfNotValid(value, isUserNotificationSettingValid, 'newFollow')
119 ) 128 )
@@ -165,7 +174,8 @@ export class UserNotificationSettingModel extends Model<UserNotificationSettingM
165 newUserRegistration: this.newUserRegistration, 174 newUserRegistration: this.newUserRegistration,
166 commentMention: this.commentMention, 175 commentMention: this.commentMention,
167 newFollow: this.newFollow, 176 newFollow: this.newFollow,
168 newInstanceFollower: this.newInstanceFollower 177 newInstanceFollower: this.newInstanceFollower,
178 autoInstanceFollowing: this.autoInstanceFollowing
169 } 179 }
170 } 180 }
171} 181}