Revert change of serializer to non-static class