Removed distribute and small fixes