Fix bug in component restart