implement auto-refreshing on save