applying some fixes