Skip to content

Commit

Permalink
Fixing encoding bug when file is already UTF-8
Browse files Browse the repository at this point in the history
  • Loading branch information
wiltonsr committed Apr 25, 2019
1 parent 9048bdc commit 2a044ba
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion Controller/TrelloJSON2KanboardController.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ public function save()
} else {
$file_content = file_get_contents($filename);

$file_content = mb_convert_encoding($file_content, 'UTF-8', 'pass');
if (!mb_check_encoding($file_content, 'UTF-8')) {
$file_content = mb_convert_encoding($file_content, 'UTF-8', 'pass');
}

$jsonObj = json_decode($file_content);

Expand Down
2 changes: 1 addition & 1 deletion Plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function getPluginAuthor()

public function getPluginVersion()
{
return '1.1.0';
return '1.1.1';
}

public function getPluginHomepage()
Expand Down

0 comments on commit 2a044ba

Please sign in to comment.