From 0e292afa028e5da68fcebe2815910b70d65d48e3 Mon Sep 17 00:00:00 2001 From: mincomk Date: Wed, 4 Jun 2025 04:10:49 +0900 Subject: [PATCH] fix: peripheral.find --- package.json | 2 +- types/index.d.ts | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index ac0c2f9..a0e2a8f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "computercraft-ts", - "version": "1.0.4", + "version": "1.0.5", "description": "", "license": "ISC", "author": "", diff --git a/types/index.d.ts b/types/index.d.ts index 8c117d6..b1a7c38 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -1102,7 +1102,10 @@ declare global { * @param peripheralType The type to search for * @returns The names of found peripherals and the wrapped peripherals */ - function find(peripheralType: string): [string, any][]; + function find( + peripheralType: string, + filter?: (name: string, wrapped: any) => boolean, + ): [string, any][]; /** * Gets the names of all attached peripherals.