Skip to content

Commit

Permalink
spelling fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dixyes committed Aug 23, 2016
1 parent 312b7ee commit 06390a2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ key can be
'api': DPlayer danmaku backend url
'id': see https://github.com/DIYgod/DPlayer
'token': see https://github.com/DIYgod/DPlayer
'maxinum': maximum quantity of danmaku
'maximum': maximum quantity of danmaku

for example:

Expand Down
8 changes: 4 additions & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ hexo.extend.filter.register('after_post_render', function(data) {

// {% dplayer key=value ... %}
hexo.extend.tag.register('dplayer', function(args) {
var url=undefined, api=undefined, loop=undefined, autoplay=undefined, theme=undefined, pic=undefined, did=undefined, token=undefined, screenshot=undefined, lang=undefined, maxinum=undefined, hotkey=undefined;
var url=undefined, api=undefined, loop=undefined, autoplay=undefined, theme=undefined, pic=undefined, did=undefined, token=undefined, screenshot=undefined, lang=undefined, maximum=undefined, hotkey=undefined;
var id = 'dplayer' + (counter++),
raw = '<div id="'+ id + '" class="dplayer" style="margin-bottom: 20px;"></div>';
for (var i = 0; i < args.length; ++i) {
Expand Down Expand Up @@ -107,8 +107,8 @@ hexo.extend.tag.register('dplayer', function(args) {
case 'token':
token = arg.slice(arg.indexOf("=")+1);
break;
case 'maxinum':
maxinum = arg.slice(arg.indexOf("=")+1);
case 'maximum':
maximum = arg.slice(arg.indexOf("=")+1);
break;
}
}
Expand All @@ -131,7 +131,7 @@ hexo.extend.tag.register('dplayer', function(args) {
api: api,
id: did,
token: token,
maxinum: maxinum
maximum: maximum
})
}).replace("\"document.getElementById('')\"",'document.getElementById("'+ id +'")') +
');</script>';
Expand Down

0 comments on commit 06390a2

Please sign in to comment.