added checking before saving property