NdNi4B and DyNi4B compounds studied by X-ray photoemission spectroscopy