Fixing bug with creating availabilities