moving code from binary to a method within the module