how to avoid loss