a lot of modifications ;-)