Skip to content

Commit e05d696

Browse files
authored
chore: update typescript (#360)
1 parent 6e8329d commit e05d696

File tree

9 files changed

+11
-12
lines changed

9 files changed

+11
-12
lines changed

jest.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ module.exports = {
55
diagnostics: {
66
// warnOnly: true,
77
},
8-
tsConfig: {
8+
tsconfig: {
99
types: [
1010
"node",
1111
"jest",

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@
4949
"@ionic/prettier-config": "^4.0.0",
5050
"@semantic-release/changelog": "^6.0.3",
5151
"@semantic-release/git": "^10.0.1",
52-
"@types/babel__traverse": "7.17.1",
5352
"@types/debug": "^4.1.10",
5453
"@types/elementtree": "^0.1.3",
5554
"@types/ini": "^1.3.32",
@@ -64,7 +63,7 @@
6463
"prettier": "^3.0.3",
6564
"semantic-release": "^19.0.5",
6665
"ts-jest": "^26.3.0",
67-
"typescript": "~4.1.2"
66+
"typescript": "~4.9.5"
6867
},
6968
"prettier": "@ionic/prettier-config",
7069
"eslintConfig": {

src/android/list.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@ export async function list(args: readonly string[]): Promise<Targets> {
1717
(async () => {
1818
try {
1919
return await getDeviceTargets(sdk);
20-
} catch (e) {
20+
} catch (e: any) {
2121
errors.push(e);
2222
return [];
2323
}
2424
})(),
2525
(async () => {
2626
try {
2727
return await getVirtualTargets(sdk);
28-
} catch (e) {
28+
} catch (e: any) {
2929
errors.push(e);
3030
return [];
3131
}

src/android/utils/sdk/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ export async function getSDKPackage(location: string): Promise<SDKPackage> {
128128
name,
129129
apiLevel,
130130
};
131-
} catch (e) {
131+
} catch (e: any) {
132132
debug('Encountered error with %s: %O', packageXmlPath, e);
133133

134134
if (e.code === 'ENOENT') {

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ export async function run(): Promise<void> {
4545

4646
throw new CLIException(`Unsupported platform: "${platform}"`, ERR_BAD_INPUT);
4747
}
48-
} catch (e) {
48+
} catch (e: any) {
4949
debug('Caught fatal error: %O', e);
5050
process.exitCode = e instanceof Exception ? e.exitCode : ExitCode.GENERAL;
5151
process.stdout.write(serializeError(e));

src/ios/lib/protocol/gdb.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ export class GDBProtocolReader extends ProtocolReader {
5353
this.onData();
5454
}
5555
}
56-
} catch (err) {
56+
} catch (err: any) {
5757
this.callback(null, err);
5858
}
5959
}

src/ios/lib/protocol/protocol.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ export abstract class ProtocolReader {
6767
this.onData();
6868
}
6969
}
70-
} catch (err) {
70+
} catch (err: any) {
7171
this.callback(null, err);
7272
}
7373
}

src/ios/list.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export async function list(args: readonly string[]): Promise<Targets> {
1919
try {
2020
const devices = await getConnectedDevices();
2121
return devices.map(deviceToTarget);
22-
} catch (e) {
22+
} catch (e: any) {
2323
errors.push(e);
2424
return [];
2525
}
@@ -28,7 +28,7 @@ export async function list(args: readonly string[]): Promise<Targets> {
2828
try {
2929
const simulators = await getSimulators();
3030
return simulators.map(simulatorToTarget);
31-
} catch (e) {
31+
} catch (e: any) {
3232
errors.push(e);
3333
return [];
3434
}

src/ios/utils/simulator.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export async function getSimulators(): Promise<SimulatorResult[]> {
6262
)
6363
.reduce((prev, next) => prev.concat(next)) // flatten
6464
.sort((a, b) => (a.name < b.name ? -1 : 1));
65-
} catch (err) {
65+
} catch (err: any) {
6666
throw new Exception(`Unable to retrieve simulator list: ${err.message}`);
6767
}
6868
}

0 commit comments

Comments
 (0)