Fixing bug when saving project