Skip to content

Commit

Permalink
Fixed spicywebau#9, no longer overwrites locale tag inside labels
Browse files Browse the repository at this point in the history
  • Loading branch information
rungta committed Jan 27, 2018
1 parent f244727 commit 18c0a41
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion relabel/resources/js/Relabel.js
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,11 @@

if(label.name)
{
$label.text(Craft.t(label.name));
var $labelText = $label.contents().filter(function () {
return this.nodeType == 3;
}).first();

$labelText.replaceWith(document.createTextNode(Craft.t(label.name)));
}

if(label.instructions)
Expand Down

0 comments on commit 18c0a41

Please sign in to comment.