zulip/web
Alex Vandiver c2e0a27d2c upload: Fix uploading the same file twice in the same session.
This commit fixes a bug where uploading the same file a second time
in the same browser session would appear to the user to stall with
`Uploading [filename]...` in the composebox.  This is because
`tus-js-client` makes a HEAD request to check for already-uploaded
files -- and, if found, that request is used in the `upload-success`
callback.  That left the callback with no response body to parse, to
know what URL to insert.

Store the `/user_uploads/...` URL in the file metadata after a
successful upload, and if the fingerprint matches a previous upload,
pull that URL (and filename, as it may have changed server-side) out
of the previous upload's metadata.

Co-authored-by: Shubham Padia <shubham@zulip.com>
2025-05-28 09:23:51 -07:00
..
e2e-tests compose_state: Rename private_message_recipient to clarify it stores emails. 2025-05-16 10:51:29 -07:00
generated
html web: Sync content of Django and nginx error pages. 2025-04-03 17:09:46 -07:00
images icons: Let the system using the icons specify the fill-rule color. 2025-05-27 10:00:21 -07:00
server katex_server: Fix import/no-named-as-default. 2024-09-25 15:41:01 -07:00
shared icons: Let the system using the icons specify the stroke property. 2025-05-27 10:00:21 -07:00
src upload: Fix uploading the same file twice in the same session. 2025-05-28 09:23:51 -07:00
styles user_circles: Adjust offline circle for gray highlight. 2025-05-21 15:27:22 -07:00
templates demo-orgs: Disable allowing users to join until owner email set. 2025-05-21 15:52:38 -07:00
tests upload: Fix uploading the same file twice in the same session. 2025-05-28 09:23:51 -07:00
third bootstrap: Rescue decoupled app, portico alert styles. 2025-04-30 10:26:20 -07:00
.browserslistrc browserslist: Add support for logical props. 2025-05-21 15:19:08 -07:00
.gitignore emoji: Convert spritesheets to webp. 2024-09-11 09:03:47 -07:00
babel.config.js dependencies: Upgrade JavaScript dependencies. 2025-05-05 14:15:44 -07:00
debug-require-webpack-plugin.ts debug-require: Rename to *.cjs. 2024-11-13 09:18:56 -08:00
debug-require.cjs debug-require: Rename to *.cjs. 2024-11-13 09:18:56 -08:00
postcss.config.js postcss: Work around postcss-extend-rule incompatibility with :is(). 2025-05-23 22:25:38 -07:00
webpack.assets.json integrations: Convert module to TypeScript. 2024-12-01 19:33:16 -08:00
webpack.config.ts webpack: Disable cross-origin-header-check middleware. 2025-04-15 16:18:06 -07:00
webpack.dev-assets.json showroom: Standardize "showroom" name for UI components testing pages. 2025-01-13 17:46:15 -08:00