This behavior causes significant performance and stability issues:
The fix involves decoupling the "Get Link" request from the generic "Get Full Contents" logic to ensure the Base64 content is only loaded when strictly necessary.
1. Frontend Action Logic (actions.es6.js):
getShareableContents.api.getContents(payload, true, false).false, we prevent the backend from encoding the file stream into the JSON response.2. Component Integration (share-modal.vue):
generateUrl method to dispatch the new getShareableContents action instead of the previous full content fetch.3. Backend Efficiency (ApiModel.php):
ApiModel.php, when the third parameter ($options['content']) of getFile() is false, the logic that executes base64_encode(stream_get_contents($resource)) is bypassed.None. Removing the Base64 content from the "Get Link" modal will not affect the file's availability or the correctness of the generated URL. It will result in a significantly faster and lighter XHR request.
| Labels |
Added:
No Code Attached Yet
|
||
Please see #44848