Fixed error introduced when backporting changes.
Removed debug logging from api.