Skip to content

Commit

Permalink
fix: support custom registry
Browse files Browse the repository at this point in the history
Signed-off-by: zxypro1 <1018995004@qq.com>
  • Loading branch information
zxypro1 committed Apr 1, 2024
1 parent 91c88f9 commit 1399e84
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/load-application/src/utils/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { endsWith, keys, replace } from 'lodash';
import { RANDOM_PATTERN, REGISTRY, GITHUB_REGISTRY } from '../constant';
import { RANDOM_PATTERN, REGISTRY } from '../constant';
import Credential from '@serverless-devs/credential';

export { default as getInputs } from './get-inputs';
Expand All @@ -11,7 +11,7 @@ export const tryfun = async (fn: Function, ...args: any[]) => {
};

export const getUrlWithLatest = (name: string) => {
if (REGISTRY.CUSTOM_URL === GITHUB_REGISTRY) {
if (REGISTRY.CUSTOM_URL !== REGISTRY.V3) {
return `${REGISTRY.CUSTOM_URL}/${name}`;
}
return `${REGISTRY.V3}/packages/${name}/release/latest`
Expand Down

0 comments on commit 1399e84

Please sign in to comment.