Updated method serialize()
Merge branch 'master' into gh-pages