mirror of
https://github.com/LemmyNet/lemmy-js-client.git
synced 2024-11-30 00:01:14 +00:00
Moving return to else.
This commit is contained in:
parent
c5fb4b559e
commit
c0281d32d8
1 changed files with 2 additions and 1 deletions
|
@ -1316,10 +1316,11 @@ export class LemmyHttp {
|
||||||
|
|
||||||
if (!response.ok) {
|
if (!response.ok) {
|
||||||
throw json["error"] ?? response.statusText;
|
throw json["error"] ?? response.statusText;
|
||||||
}
|
} else {
|
||||||
return json;
|
return json;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function encodeGetParams<BodyType extends object>(p: BodyType): string {
|
function encodeGetParams<BodyType extends object>(p: BodyType): string {
|
||||||
return Object.entries(p)
|
return Object.entries(p)
|
||||||
|
|
Loading…
Reference in a new issue