[PR #102] [CLOSED] Upload.php: Return the same JSON Structure for files that are already existing #156

Closed
opened 2026-02-25 23:40:57 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/HaschekSolutions/pictshare/pull/102
Author: @Scarwolf
Created: 11/3/2019
Status: Closed

Base: masterHead: master


📝 Commits (2)

  • 6b4347d Existing Files now return the same JSON Structure
  • 9cd70e3 Change indentation

📊 Changes

1 file changed (+9 additions, -2 deletions)

View changed files

📝 api/upload.php (+9 -2)

📄 Description

Hey there,

I was integrating Pictshare's API in the Screenshot Tool ShareX and struggling for an hour, wondering why the Script did not return the delete_url param.

Eventually I found out this was related to Sharex Uploading the same file over and over again to test and the /upload endpoint returning a different JSON Structure for files that have been uploaded before.

So I created this PR which returns the Same values as if the file uploaded would not have been uploaded before.


🔄 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/HaschekSolutions/pictshare/pull/102 **Author:** [@Scarwolf](https://github.com/Scarwolf) **Created:** 11/3/2019 **Status:** ❌ Closed **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (2) - [`6b4347d`](https://github.com/HaschekSolutions/pictshare/commit/6b4347d0d37d8770372454f114cb5070eb9f71be) Existing Files now return the same JSON Structure - [`9cd70e3`](https://github.com/HaschekSolutions/pictshare/commit/9cd70e301c8847c6cf06c2ee70ef87942384be2d) Change indentation ### 📊 Changes **1 file changed** (+9 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `api/upload.php` (+9 -2) </details> ### 📄 Description Hey there, I was integrating Pictshare's API in the Screenshot Tool ShareX and struggling for an hour, wondering why the Script did not return the `delete_url` param. Eventually I found out this was related to Sharex Uploading the same file over and over again to test and the /upload endpoint returning a different JSON Structure for files that have been uploaded before. So I created this PR which returns the Same values as if the file uploaded would not have been uploaded before. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-25 23:40:57 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/pictshare#156
No description provided.