diff --git a/package.json b/package.json index 042adde6..bc940df6 100644 --- a/package.json +++ b/package.json @@ -72,7 +72,7 @@ "husky": "^7.0.4", "import-sort-style-module": "^6.0.0", "iso-639-1": "^2.1.10", - "lemmy-js-client": "0.15.0-rc.2", + "lemmy-js-client": "0.15.0-rc.6", "lint-staged": "^12.1.2", "mini-css-extract-plugin": "^2.4.5", "node-fetch": "^2.6.1", diff --git a/src/shared/components/modlog.tsx b/src/shared/components/modlog.tsx index 2e8527d1..cc3c7a1e 100644 --- a/src/shared/components/modlog.tsx +++ b/src/shared/components/modlog.tsx @@ -25,9 +25,11 @@ import { i18n } from "../i18next"; import { InitialFetchRequest } from "../interfaces"; import { UserService, WebSocketService } from "../services"; import { + authField, fetchLimit, isBrowser, setIsoData, + setOptionalAuth, toast, wsClient, wsJsonToRes, @@ -482,6 +484,7 @@ export class Modlog extends Component { community_id: this.state.communityId, page: this.state.page, limit: fetchLimit, + auth: authField(false), }; WebSocketService.Instance.send(wsClient.getModlog(modlogForm)); @@ -507,6 +510,7 @@ export class Modlog extends Component { if (communityId) { modlogForm.community_id = Number(communityId); } + setOptionalAuth(modlogForm, req.auth); promises.push(req.client.getModlog(modlogForm)); @@ -514,6 +518,7 @@ export class Modlog extends Component { let communityForm: GetCommunity = { id: Number(communityId), }; + setOptionalAuth(communityForm, req.auth); promises.push(req.client.getCommunity(communityForm)); } return promises; diff --git a/yarn.lock b/yarn.lock index 60e4a05b..0815ba31 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4997,10 +4997,10 @@ lcid@^1.0.0: dependencies: invert-kv "^1.0.0" -lemmy-js-client@0.15.0-rc.2: - version "0.15.0-rc.2" - resolved "https://registry.yarnpkg.com/lemmy-js-client/-/lemmy-js-client-0.15.0-rc.2.tgz#e4e10edf844d90bde9915e578ced319cbd058109" - integrity sha512-qb+70MQQJ2pMNxroW+E8MNSXOrSxr3/qLO81GuAa/JT2AzbbY7mO/aXPFSrbyZWu5kn0K99alctEOC3m7mwEGw== +lemmy-js-client@0.15.0-rc.6: + version "0.15.0-rc.6" + resolved "https://registry.yarnpkg.com/lemmy-js-client/-/lemmy-js-client-0.15.0-rc.6.tgz#5f8552488ed82b8c0962c158edccb8ce1d56389e" + integrity sha512-eSEZ5+F2ScKVtx+wwjdReHirJBNLQL2YdTV4aMCBWaSsxfsXUcz18/urbNxo+fNMc7Q4u0aRd3737yKBeMP9Kw== levn@^0.4.1: version "0.4.1"