Removed debug function as unused