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:
A 2026-03-08 05:51:25 -07:00 committed by GitHub
parent 90a5174181
commit 4f528b1c77
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 3 additions and 3 deletions

View file

@ -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";

View file

@ -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;
}

View file

@ -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,