Code cleanup and remove unnecessary wrapper
wip