Refactoring ClientImage code to save client image in m_image table