Fixed AQL user function's register() not using supplied arguments.

Fixed a small bug where register() does not use the supplied `$code` and `$name` arguments. Added a test to check against that.