fixed duration bug 5
Merge pull request #16 from ealun/master

Fixed issue #5. Good!