mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-08-07 05:38:27 +02:00
Optimize + refactor code
This commit is contained in:
@@ -50,6 +50,7 @@ enum StreamBadge {
|
||||
export class StreamBadges {
|
||||
private static instance: StreamBadges;
|
||||
public static getInstance = () => StreamBadges.instance ?? (StreamBadges.instance = new StreamBadges());
|
||||
private readonly LOG_TAG = 'StreamBadges';
|
||||
|
||||
private serverInfo: StreamServerInfo = {};
|
||||
|
||||
@@ -96,6 +97,10 @@ export class StreamBadges {
|
||||
private intervalId?: number | null;
|
||||
private readonly REFRESH_INTERVAL = 3 * 1000;
|
||||
|
||||
private constructor() {
|
||||
BxLogger.info(this.LOG_TAG, 'constructor()');
|
||||
}
|
||||
|
||||
setRegion(region: string) {
|
||||
this.serverInfo.server = {
|
||||
region: region,
|
||||
|
Reference in New Issue
Block a user