If $W_x$ denotes the domain of the program with number $x$, the question is:
Is there a partial computable function $f$ such that if $W_x$ is not empty then $f(x)\in W_x$, and otherwise, $f(x)$ is undefined?
My attempt is to take $f(x)=x$ if $x\in W_x$ and otherwise, $f$ is undefined. But I don't know how to deal with the non-empty condition.