Readd missing end statement

this was lost in merge 79bc5b0