Remove console logs, move into debug parameter