Skip to content

Commit

Permalink
remove OAuth strings
Browse files Browse the repository at this point in the history
cleanup more unused code
  • Loading branch information
Daniel OBrien committed Feb 8, 2024
1 parent f2af40e commit d69bff7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
3 changes: 0 additions & 3 deletions src/commands/configureLaunchDarklyEnvironment.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import { commands, Disposable, window } from 'vscode';
//import { sortNameCaseInsensitive } from '../api';
import { extensionReload } from '../generalUtils';
import { CMD_LD_CONFIG_ENV } from '../utils/commands';
import { ILDExtensionConfiguration } from '../models';

export default async function configureEnvironmentCmd(config: ILDExtensionConfiguration): Promise<Disposable> {
const configureEnvironmentCmd = commands.registerCommand(CMD_LD_CONFIG_ENV, async () => {
try {
//const intConfig = config.getConfig();
const api = config.getApi();
if (!config.getConfig()) {
return;
Expand All @@ -17,7 +15,6 @@ export default async function configureEnvironmentCmd(config: ILDExtensionConfig
window.showErrorMessage(`[LaunchDarkly] Please Configure LaunchDarkly Extension`);
return;
}
//const environments = project.environments.sort(sortNameCaseInsensitive);
const environments = project.environments.items;
const newEnvironment = await window.showQuickPick(environments.map((env) => env.key));
if (newEnvironment) {
Expand Down
4 changes: 1 addition & 3 deletions src/providers/authProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@ import { CONST_CONFIG_LD } from '../utils/constants';

export const AUTH_TYPE = `launchdarkly`;
const AUTH_NAME = `LaunchDarkly`;
const LAUNCHDARKLY_OAUTH_DOMAIN = `hello-world-restless-violet-9097.dobrien-nj.workers.dev`; // Adjust if necessary
//const LAUNCHDARKLY_OAUTH_DOMAIN = `ldprobotdevo.ngrok.io/vscode`; // Adjust if necessary
const LAUNCHDARKLY_OAUTH_DOMAIN = ``; // Adjust if necessary
const SESSIONS_SECRET_KEY = `${AUTH_TYPE}.sessions`;

class UriEventHandler extends EventEmitter<Uri> implements UriHandler {
Expand Down Expand Up @@ -311,7 +310,6 @@ export class LaunchDarklyAuthenticationProvider implements AuthenticationProvide
Authorization: apiToken,
},
});
//const serviceTokenError = `reflexive member id 'me' is invalid when authenticated with a service token`;
const res = await response;

if (res.status == 404) {
Expand Down

0 comments on commit d69bff7

Please sign in to comment.