From 92b76e20deb0c3f5d7a1caae3d4cfc829e273ef4 Mon Sep 17 00:00:00 2001 From: syeopite Date: Wed, 14 Jul 2021 22:18:01 -0700 Subject: [PATCH] Add new user field for totp secret --- src/invidious/users.cr | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/invidious/users.cr b/src/invidious/users.cr index aff76b53..8227bc76 100644 --- a/src/invidious/users.cr +++ b/src/invidious/users.cr @@ -10,6 +10,7 @@ struct User property notifications : Array(String) property subscriptions : Array(String) property email : String + property totp_secret : String? @[DB::Field(converter: User::PreferencesConverter)] property preferences : Preferences @@ -365,6 +366,7 @@ def fetch_user(sid, headers, db) token: token, watched: [] of String, feed_needs_update: true, + totp_secret: nil, }) return user, sid end @@ -383,6 +385,7 @@ def create_user(sid, email, password) token: token, watched: [] of String, feed_needs_update: true, + totp_secret: nil, }) return user, sid