Skip to content

Commit

Permalink
Using decodeString()
Browse files Browse the repository at this point in the history
  • Loading branch information
padvincenzo authored Jun 8, 2021
1 parent 3757201 commit 3f3fb30
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions js/class.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,9 +160,9 @@ class Class {
}

update(_data) {
this.name = decodeURIComponent(_data.name);
this.professor = decodeURIComponent(_data.professor);
this.directory = decodeURIComponent(_data.directory);
this.name = decodeString(_data.name);
this.professor = decodeString(_data.professor);
this.directory = decodeString(_data.directory);
this.nLessons = _data.nLessons;
this.nWatched = _data.nWatched ? _data.nWatched : 0;

Expand Down
6 changes: 3 additions & 3 deletions js/lesson.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,9 +133,9 @@ class Lesson {

update(_data) {
this.dated = _data.dated;
this.title = decodeURIComponent(_data.title);
this.professor = decodeURIComponent(_data.professor);
this.filename = decodeURIComponent(_data.filename);
this.title = decodeString(_data.title);
this.professor = decodeString(_data.professor);
this.filename = decodeString(_data.filename);

if(this.card != null) {
this.card.title.innerText = this.title;
Expand Down

0 comments on commit 3f3fb30

Please sign in to comment.