Commit d6dbe845 authored by Dheeraj Joshi's avatar Dheeraj Joshi

Fix redirection for DAST Scanner Profile

Remove destructing of params passed to factory fn
as destructing is already handled by the factory

Changelog: fixed
EE: true
parent 72210f73
......@@ -25,12 +25,10 @@ export default () => {
props.profile = convertObjectPropsToCamelCase(JSON.parse(el.dataset.scannerProfile));
}
const returnToPreviousPage = ({ id } = {}) => {
returnToPreviousPageFactory({
allowedPaths: [onDemandScansPath, dastConfigurationPath],
profilesLibraryPath,
urlParamKey: 'scanner_profile_id',
})(id);
const factoryParams = {
allowedPaths: [onDemandScansPath, dastConfigurationPath],
profilesLibraryPath,
urlParamKey: 'scanner_profile_id',
};
return new Vue({
......@@ -40,8 +38,8 @@ export default () => {
return h(DastScannerProfileForm, {
props,
on: {
success: returnToPreviousPage,
cancel: returnToPreviousPage,
success: returnToPreviousPageFactory(factoryParams),
cancel: returnToPreviousPageFactory(factoryParams),
},
});
},
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment