Skip to content

Commit

Permalink
fix(crypto): remove side effects
Browse files Browse the repository at this point in the history
  • Loading branch information
alimd committed Oct 28, 2024
1 parent 4ee18f2 commit 852e035
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/crypto/src/pre-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type {TokenGeneratorConfig} from './token.js';
/**
* Alwatr hash generator recommended configuration for making random self-validate **user-id**.
*/
export const userIdGeneratorRecommendedConfig: HashGeneratorConfig = {
export const userIdGeneratorRecommendedConfig: HashGeneratorConfig = /* #__PURE__ */ {
prefix: 'u',
algorithm: 'sha1',
encoding: 'base64url',
Expand All @@ -14,15 +14,15 @@ export const userIdGeneratorRecommendedConfig: HashGeneratorConfig = {
/**
* Hash generator recommended configuration for making random self-validate **device-id**.
*/
export const deviceIdGeneratorRecommendedConfig: HashGeneratorConfig = {
export const deviceIdGeneratorRecommendedConfig: HashGeneratorConfig = /* #__PURE__ */ {
...userIdGeneratorRecommendedConfig,
prefix: 'd',
};

/**
* Hash generator pre configuration for making random self-validate **secrets**.
*/
export const secretGeneratorRecommendedConfig: HashGeneratorConfig = {
export const secretGeneratorRecommendedConfig: HashGeneratorConfig = /* #__PURE__ */ {
prefix: 's',
algorithm: 'sha384',
encoding: 'base64url',
Expand All @@ -32,7 +32,7 @@ export const secretGeneratorRecommendedConfig: HashGeneratorConfig = {
/**
* Token generator recommended configuration for making secure self-validate **user-token**.
*/
export const userTokenGeneratorRecommendedConfig: Omit<TokenGeneratorConfig, 'secret' | 'duration'> = {
export const userTokenGeneratorRecommendedConfig: Omit<TokenGeneratorConfig, 'secret' | 'duration'> = /* #__PURE__ */ {
prefix: 't',
algorithm: 'sha224',
encoding: 'base64url',
Expand Down

0 comments on commit 852e035

Please sign in to comment.