diff --git a/README.md b/README.md index 2737be3..4f85344 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ -vim-wakatime 0.2.1 -================== +vim-wakatime +============ Automatic time tracking for Vim. diff --git a/plugin/wakatime.vim b/plugin/wakatime.vim index fc21aee..a674f05 100644 --- a/plugin/wakatime.vim +++ b/plugin/wakatime.vim @@ -139,8 +139,8 @@ let s:VERSION = '0.2.1' return 0 endfunction - function! s:Away(now, prev) - let duration = a:now - a:prev + function! s:Away(now, last) + let duration = a:now - a:last[1] let units = 'seconds' if duration > 59 let duration = round(duration / 60)