Skip to content
This repository has been archived by the owner on Dec 11, 2024. It is now read-only.

Commit

Permalink
Prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
Kathund committed Aug 22, 2024
1 parent e27d3e9 commit 45ca036
Show file tree
Hide file tree
Showing 76 changed files with 726 additions and 1,580 deletions.
2 changes: 1 addition & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ root = true
[*]
indent_style = space
indent_size = 2
end_of_line = crlf
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = false
insert_final_newline = false
674 changes: 412 additions & 262 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

4 changes: 3 additions & 1 deletion src/API/getAchievements.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getAchievements extends Endpoint {
class getAchievements extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getAchievements extends Endpoint {
return new Achievements(res);
}
}

export default getAchievements;
4 changes: 3 additions & 1 deletion src/API/getActiveHouses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Endpoint from '../Private/Endpoint';
import House from '../structures/House';
import Client from '../Client';

export default class getActiveHouses extends Endpoint {
class getActiveHouses extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getActiveHouses extends Endpoint {
return res.length ? res.map((b: any) => new House(b)) : [];
}
}

export default getActiveHouses;
4 changes: 3 additions & 1 deletion src/API/getBoosters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Booster from '../structures/Boosters/Booster';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getBoosters extends Endpoint {
class getBoosters extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getBoosters extends Endpoint {
return res.boosters.length ? res.boosters.map((b: any) => new Booster(b)).reverse() : [];
}
}

export default getBoosters;
3 changes: 2 additions & 1 deletion src/API/getChallenges.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getChallenges extends Endpoint {
class getChallenges extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,4 @@ export default class getChallenges extends Endpoint {
return new Challenges(res);
}
}
export default getChallenges;
4 changes: 3 additions & 1 deletion src/API/getGameCounts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import GameCounts from '../structures/GameCounts';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getGameCounts extends Endpoint {
class getGameCounts extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getGameCounts extends Endpoint {
return new GameCounts(res);
}
}

export default getGameCounts;
5 changes: 3 additions & 2 deletions src/API/getGuild.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import isGuildID from '../utils/isGuildID';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getGuild extends Endpoint {
class getGuild extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -28,7 +28,8 @@ export default class getGuild extends Endpoint {
if (!res.guild && 'player' !== searchParameter) {
throw new Error(this.client.errors.GUILD_DOES_NOT_EXIST);
}

return res.guild ? new Guild(res.guild, isPlayerQuery ? query : undefined) : null;
}
}

export default getGuild;
4 changes: 3 additions & 1 deletion src/API/getGuildAchievements.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getGuildAchievements extends Endpoint {
class getGuildAchievements extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getGuildAchievements extends Endpoint {
return new GuildAchievements(res);
}
}

export default getGuildAchievements;
4 changes: 3 additions & 1 deletion src/API/getHouse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Endpoint from '../Private/Endpoint';
import House from '../structures/House';
import Client from '../Client';

export default class getHouse extends Endpoint {
class getHouse extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -17,3 +17,5 @@ export default class getHouse extends Endpoint {
return new House(res);
}
}

export default getHouse;
4 changes: 3 additions & 1 deletion src/API/getLeaderboards.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import Constants from '../utils/Constants';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getLeaderboards extends Endpoint {
class getLeaderboards extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -24,3 +24,5 @@ export default class getLeaderboards extends Endpoint {
return lbnames;
}
}

export default getLeaderboards;
4 changes: 3 additions & 1 deletion src/API/getPlayer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Endpoint from '../Private/Endpoint';
import Player from '../structures/Player';
import Client from '../Client';

export default class getPlayer extends Endpoint {
class getPlayer extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -21,3 +21,5 @@ export default class getPlayer extends Endpoint {
return new Player(res.player, options?.getGuild ? await this.client.getGuild('player', query) : undefined);
}
}

export default getPlayer;
4 changes: 3 additions & 1 deletion src/API/getPlayerHouses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Endpoint from '../Private/Endpoint';
import House from '../structures/House';
import Client from '../Client';

export default class getPlayerHouses extends Endpoint {
class getPlayerHouses extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -18,3 +18,5 @@ export default class getPlayerHouses extends Endpoint {
return res.length ? res.map((h: any) => new House(h)) : [];
}
}

export default getPlayerHouses;
4 changes: 3 additions & 1 deletion src/API/getQuests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Quests from '../structures/Static/Quests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getQuests extends Endpoint {
class getQuests extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getQuests extends Endpoint {
return new Quests(res);
}
}

export default getQuests;
4 changes: 3 additions & 1 deletion src/API/getRecentGames.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import RecentGame from '../structures/RecentGame';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getRecentGames extends Endpoint {
class getRecentGames extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -21,3 +21,5 @@ export default class getRecentGames extends Endpoint {
return res.games.map((x: any) => new RecentGame(x));
}
}

export default getRecentGames;
4 changes: 3 additions & 1 deletion src/API/getSkyblockAuction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { AuctionRequestOptions } from './API';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockAction extends Endpoint {
class getSkyblockAction extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand Down Expand Up @@ -32,3 +32,5 @@ export default class getSkyblockAction extends Endpoint {
return res.auctions.length ? res.auctions.map((a: any) => new Auction(a, options?.includeItemBytes ?? false)) : [];
}
}

export default getSkyblockAction;
4 changes: 3 additions & 1 deletion src/API/getSkyblockAuctions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export interface getSkyblockAuctionsOptions extends AuctionRequestOptions {
noInfo?: boolean;
}

export default class getSkyblockAuctions extends Endpoint {
class getSkyblockAuctions extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand Down Expand Up @@ -101,3 +101,5 @@ export default class getSkyblockAuctions extends Endpoint {
};
}
}

export default getSkyblockAuctions;
4 changes: 3 additions & 1 deletion src/API/getSkyblockAuctionsByPlayer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { AuctionRequestOptions } from './API';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockActionsByPlayer extends Endpoint {
class getSkyblockActionsByPlayer extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -18,3 +18,5 @@ export default class getSkyblockActionsByPlayer extends Endpoint {
return res.auctions.length ? res.auctions.map((a: any) => new Auction(a, options?.includeItemBytes ?? false)) : [];
}
}

export default getSkyblockActionsByPlayer;
4 changes: 3 additions & 1 deletion src/API/getSkyblockBazaar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockBazaar extends Endpoint {
class getSkyblockBazaar extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -17,3 +17,5 @@ export default class getSkyblockBazaar extends Endpoint {
return productsKeys.map((x) => new Product(res.products[x]));
}
}

export default getSkyblockBazaar;
4 changes: 3 additions & 1 deletion src/API/getSkyblockBingo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockBingo extends Endpoint {
class getSkyblockBingo extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getSkyblockBingo extends Endpoint {
return new BingoData(res);
}
}

export default getSkyblockBingo;
4 changes: 3 additions & 1 deletion src/API/getSkyblockBingoByPlayer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getBingoByPlayer extends Endpoint {
class getBingoByPlayer extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -18,3 +18,5 @@ export default class getBingoByPlayer extends Endpoint {
return new PlayerBingo(res);
}
}

export default getBingoByPlayer;
4 changes: 3 additions & 1 deletion src/API/getSkyblockFireSales.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockFireSales extends Endpoint {
class getSkyblockFireSales extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getSkyblockFireSales extends Endpoint {
return res.sales.length ? res.sales.map((a: any) => new FireSale(a)) : [];
}
}

export default getSkyblockFireSales;
4 changes: 3 additions & 1 deletion src/API/getSkyblockGarden.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockGarden extends Endpoint {
class getSkyblockGarden extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getSkyblockGarden extends Endpoint {
return new SkyblockGarden(res);
}
}

export default getSkyblockGarden;
4 changes: 3 additions & 1 deletion src/API/getSkyblockGovernment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint.js';
import Client from '../Client.js';

export default class getSkyblockGovernment extends Endpoint {
class getSkyblockGovernment extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getSkyblockGovernment extends Endpoint {
return new GovernmentData(res);
}
}

export default getSkyblockGovernment;
4 changes: 3 additions & 1 deletion src/API/getSkyblockMember.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { SkyblockRequestOptions } from './API';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockMember extends Endpoint {
class getSkyblockMember extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand Down Expand Up @@ -41,3 +41,5 @@ export default class getSkyblockMember extends Endpoint {
return memberByProfileName;
}
}

export default getSkyblockMember;
10 changes: 4 additions & 6 deletions src/API/getSkyblockMuseum.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockMuseum extends Endpoint {
class getSkyblockMuseum extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -15,10 +15,8 @@ export default class getSkyblockMuseum extends Endpoint {
query = await this.client.requests.toUUID(query);
const res = await this.client.requests.request(`/skyblock/museum?uuid=${query}&profile=${profileId}`, options);
if (res.raw) return res;
return new SkyblockMuseum({
uuid: query,
m: res,
profileId: profileId
});
return new SkyblockMuseum({ uuid: query, m: res, profileId: profileId });
}
}

export default getSkyblockMuseum;
4 changes: 3 additions & 1 deletion src/API/getSkyblockNews.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { RequestOptions } from '../Private/Requests';
import Endpoint from '../Private/Endpoint';
import Client from '../Client';

export default class getSkyblockNews extends Endpoint {
class getSkyblockNews extends Endpoint {
readonly client: Client;
constructor(client: Client) {
super(client);
Expand All @@ -16,3 +16,5 @@ export default class getSkyblockNews extends Endpoint {
return res.items.map((i: any) => new SkyblockNews(i));
}
}

export default getSkyblockNews;
Loading

0 comments on commit 45ca036

Please sign in to comment.