Corrections in update plugins function