Add 'log' decorator for debugging