diff options
Diffstat (limited to 'app/assets/javascripts/pipeline_new/utils')
-rw-r--r-- | app/assets/javascripts/pipeline_new/utils/filter_variables.js | 13 | ||||
-rw-r--r-- | app/assets/javascripts/pipeline_new/utils/format_refs.js | 18 |
2 files changed, 0 insertions, 31 deletions
diff --git a/app/assets/javascripts/pipeline_new/utils/filter_variables.js b/app/assets/javascripts/pipeline_new/utils/filter_variables.js deleted file mode 100644 index 57ce3d13a9a..00000000000 --- a/app/assets/javascripts/pipeline_new/utils/filter_variables.js +++ /dev/null @@ -1,13 +0,0 @@ -// We need to filter out blank variables -// and filter out variables that have no key -// before sending to the API to create a pipeline. - -export default (variables) => { - return variables - .filter(({ key }) => key !== '') - .map(({ variable_type, key, value }) => ({ - variable_type, - key, - secret_value: value, - })); -}; diff --git a/app/assets/javascripts/pipeline_new/utils/format_refs.js b/app/assets/javascripts/pipeline_new/utils/format_refs.js deleted file mode 100644 index f0fbc5ed7b6..00000000000 --- a/app/assets/javascripts/pipeline_new/utils/format_refs.js +++ /dev/null @@ -1,18 +0,0 @@ -import { BRANCH_REF_TYPE, TAG_REF_TYPE } from '../constants'; - -export default (refs, type) => { - let fullName; - - return refs.map((ref) => { - if (type === BRANCH_REF_TYPE) { - fullName = `refs/heads/${ref}`; - } else if (type === TAG_REF_TYPE) { - fullName = `refs/tags/${ref}`; - } - - return { - shortName: ref, - fullName, - }; - }); -}; |