Fixed mysqli errors