api: remove profile from user settings

This commit is contained in:
Abdullah Atta
2024-05-16 13:13:06 +05:00
parent 98b5143bfe
commit 1c901aad84
4 changed files with 2 additions and 13 deletions

View File

@@ -18,7 +18,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
using System;
using System.IO;
using System.Net.Http;
using System.Text;
using System.Text.Json;
using System.Threading;
using System.Threading.Tasks;
@@ -154,7 +156,6 @@ namespace Notesnook.API.Services
response.AttachmentsKey = userSettings.AttachmentsKey;
response.Salt = userSettings.Salt;
response.Subscription = subscription;
response.Profile = userSettings.Profile;
return response;
}
@@ -165,13 +166,6 @@ namespace Notesnook.API.Services
await Repositories.UsersSettings.UpdateAsync(userSettings.Id, userSettings);
}
public async Task SetUserProfileAsync(string userId, IEncrypted profile)
{
var userSettings = await Repositories.UsersSettings.FindOneAsync((u) => u.UserId == userId);
userSettings.Profile = (EncryptedData)profile;
await Repositories.UsersSettings.UpdateAsync(userSettings.Id, userSettings);
}
public async Task<bool> DeleteUserAsync(string userId, string jti)
{
try