Fixing up a possible nil ctx_root issue and removing debug