trade bugfix