Refactoring payonline integration