mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-05-05 07:07:50 +02:00
REFACTOR: Remove duplicate random alphanumeric string functions (#2601)
This commit is contained in:
@@ -3,7 +3,7 @@ import { BaseServer } from "./BaseServer";
|
||||
|
||||
import { currentNodeMults } from "../BitNode/BitNodeMultipliers";
|
||||
|
||||
import { createRandomString } from "../utils/helpers/createRandomString";
|
||||
import { getRandomAlphanumericString } from "../utils/StringHelperFunctions";
|
||||
import { createRandomIp } from "../utils/IPAddress";
|
||||
import { IReviverValue, constructorsForReviver } from "../utils/JSONReviver";
|
||||
import { IPAddress } from "../Types/strings";
|
||||
@@ -61,7 +61,7 @@ export class Server extends BaseServer {
|
||||
|
||||
// "hacknet-node-X" hostnames are reserved for Hacknet Servers
|
||||
if (this.hostname.startsWith("hacknet-node-") || this.hostname.startsWith("hacknet-server-")) {
|
||||
this.hostname = createRandomString(10);
|
||||
this.hostname = getRandomAlphanumericString(10);
|
||||
}
|
||||
|
||||
this.purchasedByPlayer = params.purchasedByPlayer != null ? params.purchasedByPlayer : false;
|
||||
|
||||
Reference in New Issue
Block a user