Skip to content

Commit

Permalink
Merge pull request #25707 from alexpavlov96/application_ioc
Browse files Browse the repository at this point in the history
added default value for ioc without application
  • Loading branch information
alexpavlov96 authored Dec 3, 2024
2 parents 193e609 + 4d5a3d2 commit d736977
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/framework/global/modularity/imodulesetup.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ class IModuleSetup

std::shared_ptr<IApplication> application() const { return m_application; }

const modularity::ContextPtr iocContext() const { return m_application->iocContext(); }
ModulesIoC* ioc() const { return m_application->ioc(); }
const modularity::ContextPtr iocContext() const { return m_application ? m_application->iocContext() : muse::modularity::globalCtx(); }
ModulesIoC* ioc() const { return m_application ? m_application->ioc() : muse::modularity::globalIoc(); }

protected:
std::shared_ptr<IApplication> m_application;
Expand Down

0 comments on commit d736977

Please sign in to comment.