mirror of
https://github.com/LemmyNet/lemmy-js-client.git
synced 2024-11-26 14:21:12 +00:00
Switching to const.
This commit is contained in:
parent
3307940dbe
commit
e19c60e341
1 changed files with 2 additions and 2 deletions
|
@ -1289,8 +1289,8 @@ export class LemmyHttp {
|
|||
|
||||
private async checkandThrowError(response: Response) {
|
||||
if (!response.ok) {
|
||||
let errJson = await response.json();
|
||||
let errString: string = errJson["error"] ?? response.statusText;
|
||||
const errJson = await response.json();
|
||||
const errString: string = errJson["error"] ?? response.statusText;
|
||||
throw new Error(errString);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue