fix by Oleg Serbin