fix: remove unused variables (#7968)

This commit is contained in:
Don Isaac
2024-08-26 02:23:56 -04:00
committed by GitHub
parent 14066965fa
commit dbcfd24ed8
18 changed files with 18 additions and 18 deletions

View File

@@ -83,7 +83,7 @@ export class AuthService implements OnApplicationBootstrap {
await this.quota.switchUserQuota(devUser.id, QuotaType.ProPlanV1);
await this.feature.addAdmin(devUser.id);
await this.feature.addCopilot(devUser.id);
} catch (e) {
} catch {
// ignore
}
}

View File

@@ -69,7 +69,7 @@ export class QuotaService {
...quota,
feature: await QuotaConfig.get(this.prisma, quota.featureId),
};
} catch (_) {}
} catch {}
return null as unknown as typeof quota & {
feature: QuotaConfig;
};

View File

@@ -21,7 +21,7 @@ export class DocID {
static parse(raw: string): DocID | null {
try {
return new DocID(raw);
} catch (e) {
} catch {
return null;
}
}

View File

@@ -140,7 +140,7 @@ export class WorkspacesController {
let ts;
try {
ts = new Date(timestamp);
} catch (e) {
} catch {
throw new InvalidHistoryTimestamp({ timestamp });
}

View File

@@ -89,7 +89,7 @@ export class URLHelper {
if (!['http:', 'https:'].includes(url.protocol)) return false;
if (!url.hostname) return false;
return true;
} catch (_) {
} catch {
return false;
}
}

View File

@@ -123,7 +123,7 @@ export class FsStorageProvider implements StorageProvider {
});
}
}
} catch (e) {
} catch {
// failed to read dir, stop recursion
}
}

View File

@@ -42,7 +42,7 @@ export async function autoMetadata(
}
return metadata;
} catch (e) {
} catch {
return metadata;
}
}

View File

@@ -43,7 +43,7 @@ export class CopilotCheckHtmlExecutor extends AutoRegisteredWorkflowExecutor {
}
}
return false;
} catch (e) {
} catch {
return false;
}
}

View File

@@ -34,7 +34,7 @@ export class CopilotCheckJsonExecutor extends AutoRegisteredWorkflowExecutor {
return true;
}
return false;
} catch (e) {
} catch {
return false;
}
}