serializing price refactored