(domain)
return chain(get_apps_in_domain(domain), _saved_apps())
Returns an iterable over all the apps ever built and current Applications.
    Used for subscription management when apps use subscription only features
    that shouldn't be present in built apps as well as app definitions.
Returns an iterable over all the apps ever built and current Applications.
    Used for subscription management when apps use subscription only features
    that shouldn't be present in built apps as well as app definitions.
Returns an iterable over all the apps ever built and current Applications . Used for subscription management when apps use subscription only features that shouldn t be present in built apps as well as app definitions .
def get_all_apps(domain):
    """
    Returns an iterable over all the apps ever built and current Applications.
    Used for subscription management when apps use subscription only features
    that shouldn't be present in built apps as well as app definitions.
    """
    def _saved_apps():
        from .models import Application
        from corehq.apps.app_manager.util import get_correct_app_class
        saved_app_ids = Application.get_db().view(
            'app_manager/saved_app',
            startkey=[domain],
            endkey=[domain, {}],
            include_docs=False,
            wrapper=lambda row: row['id'],
        )
        correct_wrap = lambda app_doc: get_correct_app_class(app_doc).wrap(app_doc)
        return map(correct_wrap, iter_docs(Application.get_db(), saved_app_ids))

    return chain(get_apps_in_domain(domain), _saved_apps())
def get_all_apps ( domain ) : def _saved_apps ( ) : from . models import Application from corehq . apps . app_manager . util import get_correct_app_class saved_app_ids = Application . get_db ( ) . view ( 'app_manager/saved_app' , startkey = [ domain ] , endkey = [ domain , { } ] , include_docs = False , wrapper = lambda row : row [ 'id' ] , ) correct_wrap = lambda app_doc : get_correct_app_class ( app_doc ) . wrap ( app_doc ) return map ( correct_wrap , iter_docs ( Application . get_db ( ) , saved_app_ids ) ) return chain ( get_apps_in_domain ( domain ) , _saved_apps ( ) )