Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support stream output #50

Merged
merged 6 commits into from Jul 10, 2023
Merged

Support stream output #50

merged 6 commits into from Jul 10, 2023

Conversation

xepozz
Copy link
Contributor

@xepozz xepozz commented Jun 9, 2023

@what-the-diff
Copy link

what-the-diff bot commented Jun 9, 2023

PR Summary

  • Changed while loop to do-while loop
    Improves code readability and flow.
  • Added check for empty string before echoing output
    Prevents echoing empty outputs, enhancing efficiency.
  • Flushes open buffers and sends echoed messages to the browser
    This prevents buffering issues when sending large responses, ensuring smoother performance with various server configurations.

Copy link
Member

@vjik vjik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests is fail... and need tests for new code.

Copy link
Member

@samdark samdark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need a CHANGELOG line + fixing tests.

@codecov
Copy link

codecov bot commented Jun 11, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.01 🎉

Comparison is base (6094dba) 99.57% compared to head (23d89de) 99.58%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master      #50      +/-   ##
============================================
+ Coverage     99.57%   99.58%   +0.01%     
- Complexity       75       77       +2     
============================================
  Files             4        4              
  Lines           235      241       +6     
============================================
+ Hits            234      240       +6     
  Misses            1        1              
Impacted Files Coverage Δ
src/SapiEmitter.php 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Member

@vjik vjik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need changelog

src/SapiEmitter.php Show resolved Hide resolved
@samdark samdark merged commit 242957c into master Jul 10, 2023
34 checks passed
@samdark
Copy link
Member

samdark commented Jul 10, 2023

👍

@samdark samdark deleted the stream-output branch July 10, 2023 15:11
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.

None yet

3 participants