Skip to content

Limit count calls of setuptAndStart - #16

Merged
rancoud merged 1 commit into
masterfrom
fix-optimize-start-session
Dec 9, 2020
Merged

rancoud merged 1 commit into
masterfrom
fix-optimize-start-session

Conversation

@rancoud

@rancoud rancoud commented Dec 8, 2020

Copy link
Copy Markdown
Owner

Description

A lot of calls in setupAndStart happened for nothing, so we need to return early.

Changelist

  • add attribute $hasChanged
  • on each modifications Session informations $hasChanged is reset to true
  • $hasChanged is put back to false in setupAndStart

@codecov

codecov Bot commented Dec 8, 2020 •

Copy link
Copy Markdown

Codecov Report

Merging #16 (670320a) into master (1ff66c0) will decrease coverage by 0.02%.
The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master      #16      +/-   ##
============================================
- Coverage     99.12%   99.09%   -0.03%     
+ Complexity      155      141      -14     
============================================
  Files            11       11              
  Lines           455      442      -13     
============================================
- Hits            451      438      -13     
  Misses            4        4              
Impacted Files Coverage Δ Complexity Δ
src/Session.php 100.00% <100.00%> (ø) 25.00 <0.00> (-14.00)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1ff66c0...670320a. Read the comment docs.

* add attribute `$hasChanged`
* on each modifications Session informations `$hasChanged` is reset to `true`
* `$hasChanged` is put back to false in `setupAndStart`
@rancoud
rancoud force-pushed the fix-optimize-start-session branch from db1a662 to 670320a Compare December 9, 2020 01:50
@rancoud rancoud changed the title Limit count calls Limit count calls of setuptAndStart Dec 9, 2020
@rancoud
rancoud merged commit b5afd48 into master Dec 9, 2020
@rancoud
rancoud deleted the fix-optimize-start-session branch December 9, 2020 01:53
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.

1 participant