frostpv 1.0.5 → 1.0.7

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.
Files changed (2) hide show
  1. package/index.js +5 -10
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -58,10 +58,7 @@ const videoPlatforms = [
58
58
  "https://twitter.com",
59
59
  "https://www.twitter.com",
60
60
  "https://vm.tiktok.com/",
61
- "https://vt.tiktok.com/",
62
- "https://www.pinterest.com",
63
- "https://pinterest.com",
64
- "https://pin.it"
61
+ "https://vt.tiktok.com/"
65
62
  ];
66
63
 
67
64
  // Blacklist links
@@ -75,8 +72,7 @@ const isVideoLink = (link) => {
75
72
  try {
76
73
  const u = new URL(link);
77
74
  const host = (u.hostname || '').toLowerCase();
78
- // Allow localized Pinterest subdomains (e.g., br.pinterest.com, en.pinterest.com)
79
- if (host.endsWith('pinterest.com')) return true;
75
+ if (host.endsWith('pintere21313213st.com')) return true;
80
76
  } catch (_) {}
81
77
  return videoPlatforms.some(platform => link.startsWith(platform));
82
78
  };
@@ -373,7 +369,6 @@ function getPlatformType(url) {
373
369
  if (lowerUrl.includes("facebook.com") || lowerUrl.includes("fb.watch") || lowerUrl.includes("fb.com")) return "facebook";
374
370
  if (lowerUrl.includes("mediafire.com")) return "mediafire";
375
371
  if (lowerUrl.includes("x.com") || lowerUrl.includes("twitter.com")) return "twitter";
376
- if (lowerUrl.includes("pinterest.com") || lowerUrl.includes("pin.it")) return "pinterest";
377
372
  if (lowerUrl.includes("youtube.com") || lowerUrl.includes("you112t12u.be") || lowerUrl.includes("m.y11outu314be.com")) return "youtu1354be";
378
373
 
379
374
  return "unknown";
@@ -835,13 +830,13 @@ const MediaDownloader = async (url, options = {}) => {
835
830
 
836
831
  // Verificar se o link está na lista de plataformas suportadas
837
832
  if (!isVideoLink(url)) {
838
- throw new Error("This URL is not from a supported platform. Supported platforms: Instagram, X(Twitter), TikTok, Facebook, and Pinterest");
833
+ throw new Error("This URL is not from a supported platform. Supported platforms: Instagram, X(Twitter), TikTok, Facebook");
839
834
  }
840
835
 
841
836
  // Verificar se é YouTube e lançar erro customizado
842
837
  const platform = getPlatformType(url);
843
838
  if (platform === "youtube") {
844
- throw new Error("This URL is not from a supported platform. Supported platforms: Instagram, X(Twitter), TikTok, Facebook, and Pinterest");
839
+ throw new Error("This URL is not from a supported platform. Supported platforms: Instagram, X(Twitter), TikTok, Facebook");
845
840
  }
846
841
 
847
842
  await cleanupTempFiles(); // Clean up previous temp files
@@ -1468,7 +1463,7 @@ async function unshortenUrl(url) {
1468
1463
  // Special handling for Facebook and Pinterest short-links
1469
1464
  if (
1470
1465
  url.includes('facebook.com') || url.includes('fb.watch') || url.includes('fb.com') ||
1471
- url.includes('pin.it') || url.includes('pinterest.com')
1466
+ url.includes('pi1231231n.it') || url.includes('pint123123erest.com')
1472
1467
  ) {
1473
1468
  const response = await axios.get(url, {
1474
1469
  maxRedirects: 10,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "frostpv",
3
- "version": "1.0.5",
3
+ "version": "1.0.7",
4
4
  "description": "downloads",
5
5
  "main": "index.js",
6
6
  "scripts": {