fixed constructor when inheriting