Refactored log module to be using Nit instead of C