Skip to content

Commit

Permalink
fix(client): decode path parameter to compat
Browse files Browse the repository at this point in the history
fix #63
  • Loading branch information
lizheming committed Dec 10, 2020
1 parent 879f620 commit aaa907e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/client/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ export default function Waline({
visitor = false,
uploadImage
} = {}) {
try {
path = decodeURI(path);
} catch(e) {
//ignore error
}

//阅读统计
if(visitor) {
const visitorPromise = path ? Visitor.add({serverURL, path}) : Promise.resolve();
Expand Down

0 comments on commit aaa907e

Please sign in to comment.