refactor: migrate to ES private fields

This commit is contained in:
Simon Chan 2023-07-11 21:05:39 +08:00
parent 433f9b986f
commit 7056feb3b1
No known key found for this signature in database
GPG key ID: A8B69F750B9BCEDD
108 changed files with 1264 additions and 1294 deletions

View file

@ -1,7 +1,7 @@
import { AdbCommandBase } from "./base.js";
export class AdbTcpIpCommand extends AdbCommandBase {
public async setPort(port: number): Promise<string> {
async setPort(port: number): Promise<string> {
if (port <= 0) {
throw new Error(`Invalid port ${port}`);
}
@ -13,7 +13,7 @@ export class AdbTcpIpCommand extends AdbCommandBase {
return output;
}
public async disable(): Promise<string> {
async disable(): Promise<string> {
const output = await this.adb.createSocketAndWait("usb:");
if (output !== "restarting in USB mode\n") {
throw new Error(output);