Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/commands/workitem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import inquirer from 'inquirer';
import chalk from 'chalk';
import ora from 'ora';
import Table from 'cli-table3';
import open from 'open';
import { ConfigManager } from '../config';
import { AdoApiClient } from '../api/client';
import { AuthManager } from '../auth';
Expand Down Expand Up @@ -398,7 +399,6 @@ async function createWorkItem(configManager: ConfigManager, options: any): Promi
console.log(`🔗 URL: ${workItem._links.html.href}`);

if (options.web) {
const open = require('open');
await open(workItem._links.html.href);
}
} catch (error) {
Expand Down Expand Up @@ -477,7 +477,6 @@ async function viewWorkItem(configManager: ConfigManager, id: number): Promise<v
console.log(`📝 Title: ${workItem.fields['System.Title']}`);
console.log(`🔗 URL: ${chalk.blue(webUrl)}`);

const open = require('open');
await open(webUrl);
} else {
throw new Error('Work item URL not available');
Expand Down