fixed cookie path and default value when setting a flag