How about moving this to AbstractHelper instead of copying the code?