updated method definition