That is already done in another commit I'll be pull requesting soon:
https://github.com/miniBill/xsp/commit/13e83199773f07979ef34f0606bdd150df4c2402