sell functions now working