Recent work showed that a theorem of Joris (that a function f is smooth if two coprime powers of f are smooth) is valid in a wide variety of ultradifferentiable classes C. The core of the proof was essentially 1-dimensional. In certain cases a multidimensional version resulted from subtle reduction arguments, but general validity, notably in the quasianalytic setting, remained open. In this paper we give a uniform proof which works in all cases and dimensions. It yields the result even on infinite dimensional Banach spaces and convenient vector spaces. We also consider more general nonlinear conditions, namely general analytic germs Φ instead of the powers, and characterize when Φ • f ∈ C implies f ∈ C.