Implemented upsert_listing method