fixed a issue where the data object was being referenced instead of
copied