fix some abstraction issues