Simplified debug function