Fix linting errors

This commit is contained in:
SleeplessOne1917 2023-09-21 21:44:49 -04:00
parent fe0281c74e
commit 366e0de216
5 changed files with 13 additions and 13 deletions

@ -1 +1 @@
Subproject commit 38bb32f6898b227aaad06a48d8bf69a5b48416d6 Subproject commit a0f95fc29b7501156b6d8bbb504b1e787b5769e7

View file

@ -1289,7 +1289,7 @@ export class Settings extends Component<any, SettingsState> {
const deleteAccountRes = await HttpService.client.deleteAccount({ const deleteAccountRes = await HttpService.client.deleteAccount({
password, password,
auth: myAuthRequired(), auth: myAuthRequired(),
// TODO: promt user weather he wants the content to be deleted // TODO: promt user weather he wants the content to be deleted,
delete_content: false, delete_content: false,
}); });
if (deleteAccountRes.state === "success") { if (deleteAccountRes.state === "success") {

View file

@ -4,5 +4,5 @@ export default function isAdmin(
creatorId: number, creatorId: number,
admins?: PersonView[], admins?: PersonView[],
): boolean { ): boolean {
return admins?.map(a => a.person.id).includes(creatorId) ?? false; return admins?.some(({ person: { id } }) => id === creatorId) ?? false;
} }

View file

@ -148,7 +148,7 @@ module.exports = (env, argv) => {
const RunNodeWebpackPlugin = require("run-node-webpack-plugin"); const RunNodeWebpackPlugin = require("run-node-webpack-plugin");
serverConfig.plugins.push( serverConfig.plugins.push(
new RunNodeWebpackPlugin({ runOnlyInWatchMode: true }) new RunNodeWebpackPlugin({ runOnlyInWatchMode: true }),
); );
} else if (mode === "none") { } else if (mode === "none") {
const { BundleAnalyzerPlugin } = require("webpack-bundle-analyzer"); const { BundleAnalyzerPlugin } = require("webpack-bundle-analyzer");