diff options
Diffstat (limited to 'app/assets/javascripts/logs/stores/mutations.js')
-rw-r--r-- | app/assets/javascripts/logs/stores/mutations.js | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/app/assets/javascripts/logs/stores/mutations.js b/app/assets/javascripts/logs/stores/mutations.js index d94d71cd25a..d77c2894a05 100644 --- a/app/assets/javascripts/logs/stores/mutations.js +++ b/app/assets/javascripts/logs/stores/mutations.js @@ -1,8 +1,9 @@ import * as types from './mutation_types'; import { convertToFixedRange } from '~/lib/utils/datetime_range'; -const mapLine = ({ timestamp, message }) => ({ +const mapLine = ({ timestamp, pod, message }) => ({ timestamp, + pod, message, }); @@ -21,6 +22,10 @@ export default { // Environments Data [types.SET_PROJECT_ENVIRONMENT](state, environmentName) { state.environments.current = environmentName; + + // Clear current pod options + state.pods.current = null; + state.pods.options = []; }, [types.REQUEST_ENVIRONMENTS_DATA](state) { state.environments.options = []; @@ -81,9 +86,6 @@ export default { [types.SET_CURRENT_POD_NAME](state, podName) { state.pods.current = podName; }, - [types.REQUEST_PODS_DATA](state) { - state.pods.options = []; - }, [types.RECEIVE_PODS_DATA_SUCCESS](state, podOptions) { state.pods.options = podOptions; }, |