Better method closure code