Fixing bug in last commit