clean up code
Small example to register replication-receiver via xquery function