using internal library
reduction of code