cleaning up update functions