Fixed fatal errors