rewrote the initialize() method