Made some bugfix after last brench merge.