improve draw algo, missing return on last valid cell