Skip to content

Commit 39b880c

Browse files
committed
use priority export for default
1 parent 475bb68 commit 39b880c

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

index.d.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { NtfyMessageOptions, NtfyMessagePriority } from './types.js';
1+
import type { NtfyMessageOptions } from './types.js';
22
/**
33
* The default ntfy server to use.
44
*/
@@ -10,11 +10,11 @@ export declare const DEFAULT_SERVER = "https://ntfy.sh";
1010
/**
1111
* The default priority to use when sending a message.
1212
*/
13-
export declare const DEFAULT_NTFY_PRIORITY: NtfyMessagePriority;
13+
export declare const DEFAULT_NTFY_PRIORITY: "3";
1414
/**
1515
* @deprecated Use `DEFAULT_NTFY_PRIORITY` instead.
1616
*/
17-
export declare const DEFAULT_PRIORITY: "default";
17+
export declare const DEFAULT_PRIORITY: "3";
1818
/**
1919
* Send a message through an ntfy server.
2020
* @param ntfyMessage The message to post.

index.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import fs from 'node:fs/promises';
2+
import { ntfyMessagePriorityDefault } from './priorities.js';
23
/**
34
* The default ntfy server to use.
45
*/
@@ -10,7 +11,7 @@ export const DEFAULT_SERVER = DEFAULT_NTFY_SERVER;
1011
/**
1112
* The default priority to use when sending a message.
1213
*/
13-
export const DEFAULT_NTFY_PRIORITY = 'default';
14+
export const DEFAULT_NTFY_PRIORITY = ntfyMessagePriorityDefault;
1415
/**
1516
* @deprecated Use `DEFAULT_NTFY_PRIORITY` instead.
1617
*/

index.ts

+3-6
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
import fs from 'node:fs/promises'
22

3-
import type {
4-
FetchHeaders,
5-
NtfyMessageOptions,
6-
NtfyMessagePriority
7-
} from './types.js'
3+
import { ntfyMessagePriorityDefault } from './priorities.js'
4+
import type { FetchHeaders, NtfyMessageOptions } from './types.js'
85

96
/**
107
* The default ntfy server to use.
@@ -19,7 +16,7 @@ export const DEFAULT_SERVER = DEFAULT_NTFY_SERVER
1916
/**
2017
* The default priority to use when sending a message.
2118
*/
22-
export const DEFAULT_NTFY_PRIORITY: NtfyMessagePriority = 'default'
19+
export const DEFAULT_NTFY_PRIORITY = ntfyMessagePriorityDefault
2320

2421
/**
2522
* @deprecated Use `DEFAULT_NTFY_PRIORITY` instead.

0 commit comments

Comments
 (0)