Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
granny authored Mar 30, 2024
1 parent 27bd662 commit ea47fc3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
7 changes: 2 additions & 5 deletions webmap/src/control/BlockInfoControl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,8 @@ export class BlockInfoControl extends ControlBox {
const tileX: number = (x / step) & 511;
const tileZ: number = (z / step) & 511;

const unknownBlock: string = this._pl3xmap.settings!.lang.blockInfo.unknown.block ?? 'Unknown block';
const unknownBiome: string = this._pl3xmap.settings!.lang.blockInfo.unknown.biome ?? 'Unknown biome';

let blockName: string = unknownBlock;
let biomeName: string = unknownBiome;
let blockName: string = this._pl3xmap.settings!.lang.blockInfo.unknown.block ?? 'Unknown block';
let biomeName: string = this._pl3xmap.settings!.lang.blockInfo.unknown.biome ?? 'Unknown biome';
let y: number | undefined;

const blockInfo: BlockInfo | undefined = this._pl3xmap.worldManager.currentWorld?.getBlockInfo(zoom, fileX, fileZ);
Expand Down
2 changes: 0 additions & 2 deletions webmap/src/settings/Lang.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ export class Label {
/**
* Represents 'unknown' values for BlockInfo.
*/

export class BlockInfoUnknown {
private readonly _block: string;
private readonly _biome: string;
Expand All @@ -109,7 +108,6 @@ export class BlockInfoUnknown {
/**
* Represents a label and a value, with 'unknown' values.
*/

export class BlockInfo extends Label {
private readonly _unknown: BlockInfoUnknown;

Expand Down

0 comments on commit ea47fc3

Please sign in to comment.