Check for ``self.onError`` is actually not needed here as the type is checked just the line above :)