Skip to content
This repository has been archived by the owner on Mar 28, 2024. It is now read-only.

Commit

Permalink
feat(logger): accident if old Alwatr.registeredList found
Browse files Browse the repository at this point in the history
  • Loading branch information
AliMD committed Oct 23, 2023
1 parent 66a8209 commit d0ae735
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/logger/src/define-package.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ Alwatr.packages ??= {};

const logger = createLogger('logger');

if ('registeredList' in Alwatr) {
logger.accident?.('define-package', 'duplicate_old_package_defined', Alwatr.registeredList);
}

export const definePackage = (packageName: string, version: string) => {
logger.logMethodArgs?.('define-package', {packageName, version});

Expand Down

0 comments on commit d0ae735

Please sign in to comment.