remove DelegatableMethod
fix formatting and missing 'end'