Fixing bug and updating comments