Fix end() method when calling with no arguments
Merge branch 'fix-end'