Fixed exceptions in core