make debug prints optional