mirror of
https://github.com/OpenRouterTeam/spawn.git
synced 2026-05-19 16:39:50 +00:00
refactor: remove unnecessary exports and fix stale comment (#2338)
- Remove `export` from `verifyOpenrouterKey` in shared/oauth.ts (only used internally) - Remove `export` from `tcpCheck` in shared/ssh.ts (only used internally) - Fix stale comment in commands/index.ts referencing non-existent `./commands.js` Co-authored-by: spawn-qa-bot <qa@openrouter.ai> Co-authored-by: L <6723574+louisgv@users.noreply.github.com>
This commit is contained in:
parent
90a5174181
commit
4f528b1c77
3 changed files with 3 additions and 3 deletions
|
|
@ -1,4 +1,4 @@
|
|||
// Barrel re-export — keeps all existing `import { ... } from "./commands.js"` working.
|
||||
// Barrel re-export — all command modules re-exported from this index.
|
||||
|
||||
// run.ts — cmdRun, cmdRunHeadless, script failure guidance
|
||||
export type { HeadlessOptions } from "./run.js";
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ const OAuthKeySchema = v.object({
|
|||
|
||||
// ─── Key Validation ──────────────────────────────────────────────────────────
|
||||
|
||||
export async function verifyOpenrouterKey(apiKey: string): Promise<boolean> {
|
||||
async function verifyOpenrouterKey(apiKey: string): Promise<boolean> {
|
||||
if (!apiKey) {
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -141,7 +141,7 @@ export function killWithTimeout(
|
|||
* Returns true if the connection succeeds within `timeoutMs`, false otherwise.
|
||||
* This is much cheaper than a full SSH handshake attempt.
|
||||
*/
|
||||
export function tcpCheck(host: string, port: number, timeoutMs = 2000): Promise<boolean> {
|
||||
function tcpCheck(host: string, port: number, timeoutMs = 2000): Promise<boolean> {
|
||||
return new Promise((resolve) => {
|
||||
const socket = connect({
|
||||
host,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue