use sugarcrm buttton when already uploaded
refactor message sniffing logic