Fix invalid access of resource properties