Skip to content
Snippets Groups Projects
Commit f510a199 authored by Rhys Arkins's avatar Rhys Arkins
Browse files

refactor(gitlab): extra strength cleanup

parent 0e0d0508
No related branches found
No related tags found
No related merge requests found
......@@ -60,6 +60,7 @@ for (const x of helpers) {
}
get.reset = function reset() {
cache = null;
cache = {};
};
......
......@@ -12,7 +12,7 @@ let config = {};
module.exports = {
getRepos,
cleanRepo: () => undefined,
cleanRepo,
initRepo,
getRepoForceRebase,
setBaseBranch,
......@@ -79,6 +79,12 @@ function urlEscape(str) {
return str ? str.replace(/\//g, '%2F') : str;
}
function cleanRepo() {
// In theory most of this isn't necessary. In practice..
get.reset();
config = {};
}
// Initialize GitLab by getting base branch
async function initRepo({ repository, token, endpoint, gitAuthor }) {
const opts = endpoints.find({ platform: 'gitlab' }, { token, endpoint });
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment