Skip to content

Commit

Permalink
Merge pull request #3843 from crazyserver/MOBILE-4362
Browse files Browse the repository at this point in the history
MOBILE-4368 lang: Fix missing lang files on gulp lang override
  • Loading branch information
dpalou authored Nov 6, 2023
2 parents dafce79 + 6a6189e commit 5287ada
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 11 deletions.
8 changes: 4 additions & 4 deletions gulp/task-override-lang.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class OverrideLangTask {
plainid = exp.join('.');
}

const component_slashes = component.replace('_', '/');
const component_slashes = component.replace(/_/g, '/');

switch (type) {
case 'core':
Expand Down Expand Up @@ -82,15 +82,15 @@ class OverrideLangTask {
}

const paths = Object.keys(files);
gulp.src(paths, { allowEmpty: true })
gulp.src(paths)
.pipe(slash())
.pipe(through(function(destFile) {
.pipe(through(function (destFile) {
const oldContents = self.readFile(destFile);
destFile.contents = self.jsonFile(oldContents, files[destFile.path]);

this.emit('data', destFile);
}))
.pipe(gulp.dest((data) => data.base, { overwrite: true}))
.pipe(gulp.dest((data) => data.base, { overwrite: true }))
.on('end', done);
}

Expand Down
2 changes: 1 addition & 1 deletion src/addons/mod/assign/feedback/comments/lang.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"pluginname": "Feedback comments"
}
}
2 changes: 1 addition & 1 deletion src/addons/mod/assign/feedback/editpdf/lang.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"pluginname": "Annotate PDF"
}
}
2 changes: 1 addition & 1 deletion src/addons/mod/assign/feedback/file/lang.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"pluginname": "File feedback"
}
}
2 changes: 1 addition & 1 deletion src/addons/mod/assign/submission/comments/lang.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"pluginname": "Submission comments"
}
}
2 changes: 1 addition & 1 deletion src/addons/mod/assign/submission/file/lang.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"pluginname": "File submissions"
}
}
2 changes: 1 addition & 1 deletion src/addons/mod/assign/submission/onlinetext/lang.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"pluginname": "Online text submissions",
"wordlimitexceeded": "The word limit for this assignment is {{$a.limit}} words and you are attempting to submit {{$a.count}} words. Please review your submission and try again."
}
}
2 changes: 1 addition & 1 deletion src/addons/mod/workshop/assessment/rubric/lang.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"dimensionnumber": "Criterion {{$a}}",
"mustchooseone": "You have to select one of these items"
}
}

0 comments on commit 5287ada

Please sign in to comment.