some changes for adaptor