A new result on averaging theory for a class of discontinuous planar differential systems with applications (Revista matemática iberoamericana, 2017)