fixed bug with last property value not set correctly