Skip to content
This repository has been archived by the owner on Oct 25, 2022. It is now read-only.

Commit

Permalink
style: Fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
oliversalzburg committed Jun 24, 2022
1 parent a7366ca commit 6196b11
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions packages/userscript/source/Engine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1517,7 +1517,7 @@ export class Engine {
buildManager.manager.render();

const metaData: Partial<Record<SpaceItem, SpaceBuildingInfo>> = {};
for (const [name, build] of objectEntries(builds)) {
for (const [name] of objectEntries(builds)) {
metaData[name] = buildManager.getBuild(name);
}

Expand Down Expand Up @@ -1974,7 +1974,7 @@ export class Engine {
}
}

for (const [name, emBulk] of objectEntries(embassyBulk)) {
for (const [, emBulk] of objectEntries(embassyBulk)) {
if (emBulk.val === 0) {
continue;
}
Expand Down
2 changes: 1 addition & 1 deletion packages/userscript/source/options/ResourcesSettings.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Resource, ResourceCraftable } from "../types";
import { Resource } from "../types";

export type ResourcesSettingsItem = {
consume?: number;
Expand Down
6 changes: 3 additions & 3 deletions packages/userscript/source/types/space.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { BuildButton, GameTab, Panel, Price } from ".";
import { GameTab, Panel, Price } from ".";

export type SpaceTab = GameTab & {
GCPanel: Panel;
Expand Down Expand Up @@ -34,8 +34,8 @@ export type SpaceBuildingInfo = {
* An internationalized label for this space building.
*/
label: string;
name:SpaceBuildings;
priceRatio:number;
name: SpaceBuildings;
priceRatio: number;
prices: Array<Price>;

unlocked: boolean;
Expand Down
6 changes: 3 additions & 3 deletions packages/userscript/source/ui/CraftSettingsUi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ export class CraftSettingsUi extends SettingsSectionUi<CraftSettings> {
option.limited = state.items[name].limited;
}
// Remove old resource options.
for (const [name, option] of objectEntries(this._options.resources)) {
for (const [name] of objectEntries(this._options.resources)) {
this._removeResourceOption(name);
}
// Add new resource options.
Expand All @@ -394,11 +394,11 @@ export class CraftSettingsUi extends SettingsSectionUi<CraftSettings> {
mustExist(this._options.$enabled).prop("checked", this._options.enabled);
mustExist(this._options.$trigger)[0].title = this._options.trigger.toFixed(2);

for (const [name, option] of objectEntries(this._options.items)) {
for (const [, option] of objectEntries(this._options.items)) {
mustExist(option.$enabled).prop("checked", option.enabled);
mustExist(option.$limited).prop("checked", option.limited);
}
for (const [name, option] of objectEntries(this._options.resources)) {
for (const [, option] of objectEntries(this._options.resources)) {
mustExist(option.$consume).text(
this._host.i18n("resources.consume", [
(option.consume ?? this._host.options.consume).toFixed(2),
Expand Down
2 changes: 1 addition & 1 deletion packages/userscript/source/ui/TimeControlSettingsUi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1343,7 +1343,7 @@ export class TimeControlSettingsUi extends SettingsSectionUi<TimeControlSettings
)
) {
// Remove existing elements.
for (const [name, resource] of objectEntries(this._options.resources)) {
for (const [, resource] of objectEntries(this._options.resources)) {
if (!isNil(resource.$checkForReset)) {
resource.$checkForReset.remove();
resource.$checkForReset = undefined;
Expand Down

0 comments on commit 6196b11

Please sign in to comment.