fixed bug in dealing with formes