({ commit }, interactiveIdOrSlug)
| 111 | |
| 112 | actions: { |
| 113 | async loadInteractive ({ commit }, interactiveIdOrSlug) { |
| 114 | commit('toggleInteractiveLoading') |
| 115 | |
| 116 | try { |
| 117 | const interactive = await getInteractive(interactiveIdOrSlug) |
| 118 | if (!interactive) { |
| 119 | throw new Error('Invalid interactive received') |
| 120 | } |
| 121 | |
| 122 | commit('addInteractive', interactive) |
| 123 | } catch (e) { |
| 124 | // TODO handle_error_ozaria |
| 125 | throw new Error('Failed to load interactive') |
| 126 | } finally { |
| 127 | commit('toggleInteractiveLoading') |
| 128 | } |
| 129 | }, |
| 130 | |
| 131 | async loadInteractiveSession ({ commit }, { interactiveIdOrSlug, sessionOptions }) { |
| 132 | commit('toggleInteractiveSessionLoading') |
nothing calls this directly
no test coverage detected