small fix to error message
Fix the 'begin' and 'end' parameters