added basic type check to tryWritePort

This commit is contained in:
phyzical
2022-02-07 22:14:48 +08:00
parent 6ed5a445a8
commit e8954bc1ee
3 changed files with 8 additions and 2 deletions

View File

@@ -5555,7 +5555,7 @@ export interface NS extends Singularity {
* @param data - Data to write.
* @returns True if the data is successfully written to the port, and false otherwise.
*/
tryWritePort(port: number, data: string[] | number): Promise<boolean>;
tryWritePort(port: number, data: string | number): Promise<boolean>;
/**
* Read content of a file.