[PR #1299] [MERGED] api/pinterest: return fetch.empty if a link is invalid #10807

Closed
opened 2026-04-27 15:09:00 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/imputnet/cobalt/pull/1299
Author: @hyperdefined
Created: 5/30/2025
Status: Merged
Merged: 6/8/2025
Merged by: @wukko

Base: developHead: specify-pinterest-error


📝 Commits (3)

  • cb78dd1 api/pinterest: fetch.empty for invalid links
  • 82fa660 api/pinterest: better regex naming
  • ff0500a api/tests/pinterest: specify errorCode for invalid

📊 Changes

2 files changed (+15 additions, -0 deletions)

View changed files

📝 api/src/processing/services/pinterest.js (+5 -0)
📝 api/src/util/tests/pinterest.json (+10 -0)

📄 Description

This simply checks if the pin linked is valid, and throws the proper error that it can't find the media.

Before

firefox_2025-05-30_15-49-56

After

firefox_2025-05-30_15-50-30


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/imputnet/cobalt/pull/1299 **Author:** [@hyperdefined](https://github.com/hyperdefined) **Created:** 5/30/2025 **Status:** ✅ Merged **Merged:** 6/8/2025 **Merged by:** [@wukko](https://github.com/wukko) **Base:** `develop` ← **Head:** `specify-pinterest-error` --- ### 📝 Commits (3) - [`cb78dd1`](https://github.com/imputnet/cobalt/commit/cb78dd1db9846a8da945f189d9c3cba43dc4e2b1) api/pinterest: `fetch.empty` for invalid links - [`82fa660`](https://github.com/imputnet/cobalt/commit/82fa66056866698853484b2f8c2f1c86a3b7a743) api/pinterest: better regex naming - [`ff0500a`](https://github.com/imputnet/cobalt/commit/ff0500aeecfb77205358841824c0fa270ca57a03) api/tests/pinterest: specify errorCode for invalid ### 📊 Changes **2 files changed** (+15 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `api/src/processing/services/pinterest.js` (+5 -0) 📝 `api/src/util/tests/pinterest.json` (+10 -0) </details> ### 📄 Description This simply checks if the pin linked is valid, and throws the proper error that it can't find the media. ## Before ![firefox_2025-05-30_15-49-56](https://github.com/user-attachments/assets/0d2a1569-e4de-45cb-aa15-98735e901561) ## After ![firefox_2025-05-30_15-50-30](https://github.com/user-attachments/assets/0fb0680a-3cbf-48a3-aa4b-0a8ad3bf91f4) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-27 15:09:00 -05:00
Sign in to join this conversation.