]> Untitled Git - lemmy.git/commitdiff
Trying to fix save user settings.
authorDessalines <tyhou13@gmx.com>
Mon, 4 Jan 2021 19:09:53 +0000 (14:09 -0500)
committerDessalines <tyhou13@gmx.com>
Mon, 4 Jan 2021 19:09:53 +0000 (14:09 -0500)
api_tests/package.json
api_tests/src/shared.ts
api_tests/src/user.spec.ts
api_tests/yarn.lock

index 13c194963a1db0e43f63aaaa1410a5ead3baf6ae..6a9a4d6d9772ee508815419254c609edfacb5618 100644 (file)
@@ -14,7 +14,7 @@
   "devDependencies": {
     "@types/jest": "^26.0.19",
     "jest": "^26.6.3",
-    "lemmy-js-client": "1.0.17-beta3",
+    "lemmy-js-client": "1.0.17-beta6",
     "node-fetch": "^2.6.1",
     "ts-jest": "^26.4.4",
     "prettier": "^2.1.2",
index 8e6d5334847c17382f129630b52850c3891c7271..207870388950601f3247bb378aae4b6d6bb18601 100644 (file)
@@ -551,8 +551,8 @@ export async function saveUserSettingsBio(
   let form: SaveUserSettings = {
     show_nsfw: true,
     theme: 'darkly',
-    default_sort_type: SortType.Active,
-    default_listing_type: ListingType.All,
+    default_sort_type: Object.keys(SortType).indexOf(SortType.Active),
+    default_listing_type: Object.keys(ListingType).indexOf(ListingType.All),
     lang: 'en',
     show_avatars: true,
     send_notifications_to_email: false,
index 7886f8eb42003275cd1fce6e679508824c48d930..4352aa4232a980169e4743429dad5079680e07b2 100644 (file)
@@ -44,8 +44,8 @@ test('Set some user settings, check that they are federated', async () => {
   let form: SaveUserSettings = {
     show_nsfw: false,
     theme: '',
-    default_sort_type: SortType.Hot,
-    default_listing_type: ListingType.All,
+    default_sort_type: Object.keys(SortType).indexOf(SortType.Hot),
+    default_listing_type: Object.keys(ListingType).indexOf(ListingType.All),
     lang: '',
     avatar,
     banner,
index 3a59e67379482b4ba82bdb6bb5d8d426f2cd67da..aacf187416a1ed36d9125aa88f0e44ec36ebdfb0 100644 (file)
@@ -3210,10 +3210,10 @@ language-tags@^1.0.5:
   dependencies:
     language-subtag-registry "~0.3.2"
 
-lemmy-js-client@1.0.17-beta3:
-  version "1.0.17-beta3"
-  resolved "https://registry.yarnpkg.com/lemmy-js-client/-/lemmy-js-client-1.0.17-beta3.tgz#ad53f3fd57e7656732f0ccde4f6b22242d77fd9b"
-  integrity sha512-0GIStZtmkCZmKk12faEusYyEIdDhhnSZ52HIu1b8rPhl68OrxVYBRbl2DQC6Ue7LFR2yMsa1q6Mp1UrTCTssRA==
+lemmy-js-client@1.0.17-beta6:
+  version "1.0.17-beta6"
+  resolved "https://registry.yarnpkg.com/lemmy-js-client/-/lemmy-js-client-1.0.17-beta6.tgz#afe1e1da13172a161c4d976b1ee58fe81eb22829"
+  integrity sha512-+oX7J7wht8nH4a5NQngK1GNner3TDv6ZOhQQVI5KcK7vynVVIcgveC5KBJArHBAl5acXpLs3Khmx0ZEb+sErJA==
 
 leven@^3.1.0:
   version "3.1.0"