Commit 26d8d0ee authored by Jacob Schatz's avatar Jacob Schatz Committed by Eric Eastwood

Uses path.

parent 3837311b
...@@ -13,7 +13,7 @@ const RepoCommitSection = { ...@@ -13,7 +13,7 @@ const RepoCommitSection = {
computed: { computed: {
branchPaths() { branchPaths() {
const branch = this.currentBranch; const branch = this.currentBranch;
return this.changedFiles.map(f => Helper.getFilePathFromFullPath(f.url, branch)); return this.changedFiles.map(f => f.path);
}, },
cantCommitYet() { cantCommitYet() {
...@@ -30,11 +30,13 @@ const RepoCommitSection = { ...@@ -30,11 +30,13 @@ const RepoCommitSection = {
// see https://docs.gitlab.com/ce/api/commits.html#create-a-commit-with-multiple-files-and-actions // see https://docs.gitlab.com/ce/api/commits.html#create-a-commit-with-multiple-files-and-actions
const branch = Store.currentBranch; const branch = Store.currentBranch;
const commitMessage = this.commitMessage; const commitMessage = this.commitMessage;
const actions = this.changedFiles.map(f => ({ const actions = this.changedFiles.map(f => {
action: 'update', return {
file_path: Helper.getFilePathFromFullPath(f.url, branch), action: 'update',
content: f.newContent, file_path: f.path,
})); content: f.newContent,
};
});
const payload = { const payload = {
branch: Store.targetBranch, branch: Store.targetBranch,
commit_message: commitMessage, commit_message: commitMessage,
......
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