recker 1.0.20-next.9796be9 → 1.0.20-next.b961eae
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/tui/shell.js +1 -1
- package/dist/plugins/cache.js +1 -1
- package/dist/plugins/retry.js +2 -2
- package/dist/transport/undici.js +1 -1
- package/dist/utils/dns-toolkit.js +1 -1
- package/dist/utils/dns.js +2 -2
- package/dist/utils/optional-require.js +1 -1
- package/dist/webrtc/index.js +1 -1
- package/package.json +1 -1
package/dist/cli/tui/shell.js
CHANGED
|
@@ -1716,7 +1716,7 @@ ${colors.bold('Network:')}
|
|
|
1716
1716
|
console.log(colors.gray(` Names: ${mapData.names.length}`));
|
|
1717
1717
|
console.log(colors.bold('\nOriginal sources:'));
|
|
1718
1718
|
mapData.sources.forEach((source, i) => {
|
|
1719
|
-
const hasContent = mapData.sourcesContent
|
|
1719
|
+
const hasContent = mapData.sourcesContent?.[i];
|
|
1720
1720
|
const sizeInfo = hasContent
|
|
1721
1721
|
? colors.green(`[${(mapData.sourcesContent[i].length / 1024).toFixed(1)}kb]`)
|
|
1722
1722
|
: colors.yellow('[no content]');
|
package/dist/plugins/cache.js
CHANGED
package/dist/plugins/retry.js
CHANGED
|
@@ -83,7 +83,7 @@ export function retry(options = {}) {
|
|
|
83
83
|
if (onRetry) {
|
|
84
84
|
onRetry(attempt, err, delayMs);
|
|
85
85
|
}
|
|
86
|
-
if (client.hooks
|
|
86
|
+
if (client.hooks?.onRetry) {
|
|
87
87
|
for (const hook of client.hooks.onRetry) {
|
|
88
88
|
await hook(err, attempt, delayMs, req);
|
|
89
89
|
}
|
|
@@ -99,7 +99,7 @@ export function retry(options = {}) {
|
|
|
99
99
|
if (onRetry) {
|
|
100
100
|
onRetry(attempt, error, delayMs);
|
|
101
101
|
}
|
|
102
|
-
if (client.hooks
|
|
102
|
+
if (client.hooks?.onRetry) {
|
|
103
103
|
for (const hook of client.hooks.onRetry) {
|
|
104
104
|
await hook(error, attempt, delayMs, req);
|
|
105
105
|
}
|
package/dist/transport/undici.js
CHANGED
|
@@ -23,7 +23,7 @@ undiciRequestChannel.subscribe((message) => {
|
|
|
23
23
|
});
|
|
24
24
|
undiciBodySentChannel.subscribe((message) => {
|
|
25
25
|
const store = requestStorage.getStore();
|
|
26
|
-
if (store
|
|
26
|
+
if (store?.hooks && store.hooks.onRequestSent) {
|
|
27
27
|
store.hooks.onRequestSent();
|
|
28
28
|
}
|
|
29
29
|
});
|
|
@@ -88,7 +88,7 @@ export async function getSecurityRecords(domain) {
|
|
|
88
88
|
try {
|
|
89
89
|
const dmarcRecords = await dns.resolveTxt(`_dmarc.${domain}`);
|
|
90
90
|
const dmarcTxt = dmarcRecords.map(chunks => chunks.join(''))[0];
|
|
91
|
-
if (dmarcTxt
|
|
91
|
+
if (dmarcTxt?.startsWith('v=DMARC1')) {
|
|
92
92
|
results.dmarc = dmarcTxt;
|
|
93
93
|
}
|
|
94
94
|
}
|
package/dist/utils/dns.js
CHANGED
|
@@ -3,7 +3,7 @@ import { promisify } from 'node:util';
|
|
|
3
3
|
const lookupAsync = promisify(lookup);
|
|
4
4
|
export function createLookupFunction(options) {
|
|
5
5
|
return (hostname, opts, callback) => {
|
|
6
|
-
if (options.override
|
|
6
|
+
if (options.override?.[hostname]) {
|
|
7
7
|
const ip = options.override[hostname];
|
|
8
8
|
const family = ip.includes(':') ? 6 : 4;
|
|
9
9
|
return callback(null, ip, family);
|
|
@@ -12,7 +12,7 @@ export function createLookupFunction(options) {
|
|
|
12
12
|
};
|
|
13
13
|
}
|
|
14
14
|
export async function customDNSLookup(hostname, options = {}) {
|
|
15
|
-
if (options.override
|
|
15
|
+
if (options.override?.[hostname]) {
|
|
16
16
|
const ip = options.override[hostname];
|
|
17
17
|
const family = ip.includes(':') ? 6 : 4;
|
|
18
18
|
return { address: ip, family };
|
|
@@ -55,7 +55,7 @@ export async function requireOptional(packageName, submodule) {
|
|
|
55
55
|
const err = error;
|
|
56
56
|
const isModuleNotFound = err.code === 'ERR_MODULE_NOT_FOUND' ||
|
|
57
57
|
err.code === 'MODULE_NOT_FOUND' ||
|
|
58
|
-
(err.message
|
|
58
|
+
(err.message?.includes('Cannot find module'));
|
|
59
59
|
if (isModuleNotFound) {
|
|
60
60
|
const info = OPTIONAL_DEPENDENCIES[packageName];
|
|
61
61
|
const sub = submodule || info?.submodule || 'this feature';
|
package/dist/webrtc/index.js
CHANGED
|
@@ -246,7 +246,7 @@ export class WebRTCClient extends EventEmitter {
|
|
|
246
246
|
if (message.to !== this.peerId)
|
|
247
247
|
return;
|
|
248
248
|
const pc = this.connections.get(message.from);
|
|
249
|
-
if (pc
|
|
249
|
+
if (pc?.remoteDescription) {
|
|
250
250
|
await pc.addIceCandidate(message.payload);
|
|
251
251
|
}
|
|
252
252
|
else {
|