initialize hooks in extend