Skip to content

Fix call downstream middleware twice#2839

Merged
compulim merged 7 commits intomicrosoft:masterfrom
compulim:fix-2838
Jan 23, 2020
Merged

Fix call downstream middleware twice#2839
compulim merged 7 commits intomicrosoft:masterfrom
compulim:fix-2838

Conversation

@compulim
Copy link
Copy Markdown
Contributor

@compulim compulim commented Jan 22, 2020

Fixes #2838.

Changelog Entry

Fixed

  • Fixes #2838. Fixed concatMiddleware should allow any middleware to call its downstream middleware twice, by @compulim in PR #2839

Description

Allow a middleware to call downstream middleware twice. There are two call patterns:

  • Handled by downstream middleware A first, return the result. Then on second call, middleware A skipped and fallback to middleware B, then return the result
  • Handled by downstream middleware A twice, no fallback to other middleware

Specific Changes

  • Updated concatMiddleware.js
  • Added unit tests for concatMiddleware.js
  • Added integration test with previewing uploading
    • image

  • Testing Added

Comment thread packages/component/src/Middleware/concatMiddleware.spec.js Outdated
@compulim compulim merged commit d1a7afb into microsoft:master Jan 23, 2020
@compulim compulim deleted the fix-2838 branch January 23, 2020 02:06
@compulim compulim mentioned this pull request Mar 5, 2020
40 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Concat middleware failed to run next middleware twice

2 participants