Fixed syntax issues and re-added logging