castillo-io / angular-css

CSS on-demand for AngularJS [Looking for New Maintainers]
http://castillo-io.github.io/angular-css/#/
MIT License
470 stars 86 forks source link

$css.preload: calling the callback when it fails. #70

Open iangregsondev opened 8 years ago

iangregsondev commented 8 years ago

Hi,

Just a suggestion but the $css.preload only calls the callback when there is no error.

Probably be better to either call the callback passing in an error object when a failure happens or changing is to a promise so we can chain "then" and "catch"