Added changes from Michal