Add completion support
Fix return value to correct position