made some changes to trim container