added second parameter for calling drawLine function