Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes nathanford#8 to my knowledge and tests.
Problem: scount gets passed over into the web request and doesn't call runFills until scount == 1. The problem is that if you have multiple files being requested they will asynchronously complete at different times rather than sequentially as the code would expect to be ran when the last scount comes through. If you have styling that isn't in the first styling sheet and it's first to complete then it calls runFills which will only consist of the first sheet and not the rest. (Assuming it's collecting all the styles before checking for fills) Fix: Implemented a global counter that increments for each sheet and decrements when it's finished, whether it's inline or requested. Once all sheets have been collected runFills is then called. Extra: I was going to implement a 304 check, but it seems it never fired, so I removed it.
- Loading branch information