1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 09:46:22 +00:00

change getTodoState to getTodoStatus

This commit is contained in:
XGHeaven
2017-08-10 19:58:58 +08:00
parent 1c7cba2951
commit e934182e86
4 changed files with 7 additions and 7 deletions

View File

@@ -1,4 +1,4 @@
export function getTodoState (content) {
export function getTodoStatus (content) {
let splitted = content.split('\n')
let numberOfTodo = 0
let numberOfCompletedTodo = 0
@@ -20,6 +20,6 @@ export function getTodoState (content) {
}
export function getTodoPercentageOfCompleted (content) {
const state = getTodoState(content)
const state = getTodoStatus(content)
return Math.floor(state.completed / state.total * 100)
}