Made design of cfunction a little more messy, so that tables may be added cleanly
Removed unnecessary redirection