Core: added var type check to escape method of db-driver classes
Core: fix of AForm class.