I would like to find out whether or not it is applicable to use two Factories in AngularJS and basically call one from the other.
Consider this Scenario:
I have a Factory returning an Array. This Factory is ought to verify whether or not Data to fill this Array is already in a local SQL Storage.
If TRUE it returns this Data back to my Controller.
If FALSE its supposed to call another Factory which consumes Data from a RESTful API. It then writes this Data to the WebSQL DB and finally returns this Data.
Does this Design follow standard Software-Patterns? I'm having a hard time to apply AngularJS Techniques to my Project...