changed initialization method