added addSerializer function