podresource: move the checkForTopology logic inline
podresource: move the checkForTopology logic inline

As per the recommendation here: https://github.com/kubernetes/kubernetes/pull/103289#pullrequestreview-766949859
we move the check inline.

Signed-off-by: Swati Sehgal <391a751e1edbb1bba93d44382a9262f4d9da2c07@redhat.com>

deads2k/kubernetes,PiotrProkop/kubernetes,jingxu97/kubernetes,jackfrancis/kubernetes,MikeSpreitzer/kubernetes,mikebrow/kubernetes,matthyx/kubernetes,li-ang/kubernetes,iameli/kubernetes,rnaveiras/kubernetes,roberthbailey/kubernetes,deads2k/kubernetes,spzala/kubernetes,jessfraz/kubernetes,zhangmingld/kubernetes,lojies/kubernetes,humblec/kubernetes,feiskyer/kubernetes,rrati/kubernetes,carlory/kubernetes,verb/kubernetes,gnufied/kubernetes,rafax/kubernetes,k82cn/kubernetes,jessfraz/kubernetes,wongma7/kubernetes,mengqiy/kubernetes,mikedanese/kubernetes,monopole/kubernetes,aledbf/kubernetes,aledbf/kubernetes,spzala/kubernetes,rafax/kubernetes,mkumatag/kubernetes,cblecker/kubernetes,rafax/kubernetes,chestack/kubernetes,jsafrane/kubernetes,thockin/kubernetes,dims/kubernetes,nikhita/kubernetes,li-ang/kubernetes,feiskyer/kubernetes,nckturner/kubernetes,nikhita/kubernetes,enj/kubernetes,gnufied/kubernetes,kevin-wangzefeng/kubernetes,bparees/kubernetes,sdminonne/kubernetes,openshift/kubernetes,jessfraz/kubernetes,PiotrProkop/kubernetes,sdminonne/kubernetes,soltysh/kubernetes,carlory/kubernetes,feiskyer/kubernetes,PiotrProkop/kubernetes,hex108/kubernetes,matthyx/kubernetes,jsafrane/kubernetes,roberthbailey/kubernetes,mosoft521/kubernetes,csrwng/kubernetes,soltysh/kubernetes,mahak/kubernetes,chestack/kubernetes,zhouhaibing089/kubernetes,fanzhangio/kubernetes,tengqm/kubernetes,tpepper/kubernetes,rnaveiras/kubernetes,jsafrane/kubernetes,hex108/kubernetes,BenTheElder/kubernetes,ii/kubernetes,ravilr/kubernetes,dixudx/kubernetes,enj/kubernetes,BenTheElder/kubernetes,tengqm/kubernetes,mosoft521/kubernetes,gnufied/kubernetes,nckturner/kubernetes,fabriziopandini/kubernetes,jingxu97/kubernetes,jackfrancis/kubernetes,shyamjvs/kubernetes,roberthbailey/kubernetes,warmchang/kubernetes,humblec/kubernetes,alejandroEsc/kubernetes,sdminonne/kubernetes,kevin-wangzefeng/kubernetes,lojies/kubernetes,k82cn/kubernetes,dixudx/kubernetes,rrati/kubernetes,humblec/kubernetes,mengqiy/kubernetes,GulajavaMinistudio/kubernetes,k82/kubernetes,linux-on-ibm-z/kubernetes,nckturner/kubernetes,kubernetes/kubernetes,rrati/kubernetes,thockin/kubernetes,alejandroEsc/kubernetes,mengqiy/kubernetes,tpepper/kubernetes,micahhausler/kubernetes,mikebrow/kubernetes,kubernetes/kubernetes,mosoft521/kubernetes,thockin/kubernetes,zhouhaibing089/kubernetes,wongma7/kubernetes,sdminonne/kubernetes,kubernetes/kubernetes,warmchang/kubernetes,hex108/kubernetes,mikebrow/kubernetes,shyamjvs/kubernetes,shyamjvs/kubernetes,rafax/kubernetes,mkumatag/kubernetes,nckturner/kubernetes,soltysh/kubernetes,cblecker/kubernetes,nikhita/kubernetes,gnufied/kubernetes,zhangmingld/kubernetes,enj/kubernetes,zhangmingld/kubernetes,chestack/kubernetes,mkumatag/kubernetes,carlory/kubernetes,matthyx/kubernetes,dims/kubernetes,spzala/kubernetes,iameli/kubernetes,chestack/kubernetes,dims/kubernetes,jagosan/kubernetes,deads2k/kubernetes,verb/kubernetes,micahhausler/kubernetes,carlory/kubernetes,ii/kubernetes,rrati/kubernetes,openshift/kubernetes,gnufied/kubernetes,olivierlemasle/kubernetes,micahhausler/kubernetes,thockin/kubernetes,mahak/kubernetes,spzala/kubernetes,aledbf/kubernetes,mikedanese/kubernetes,cblecker/kubernetes,csrwng/kubernetes,fanzhangio/kubernetes,rrati/kubernetes,warmchang/kubernetes,feiskyer/kubernetes,li-ang/kubernetes,zhangmingld/kubernetes,rnaveiras/kubernetes,mengqiy/kubernetes,tpepper/kubernetes,GulajavaMinistudio/kubernetes,matthyx/kubernetes,micahhausler/kubernetes,jackfrancis/kubernetes,deads2k/kubernetes,nikhita/kubernetes,ravilr/kubernetes,fabriziopandini/kubernetes,bparees/kubernetes,linux-on-ibm-z/kubernetes,fabriziopandini/kubernetes,mahak/kubernetes,csrwng/kubernetes,alejandroEsc/kubernetes,cblecker/kubernetes,humblec/kubernetes,PiotrProkop/kubernetes,iameli/kubernetes,ii/kubernetes,bparees/kubernetes,k82/kubernetes,zhangmingld/kubernetes,dims/kubernetes,li-ang/kubernetes,ii/kubernetes,enj/kubernetes,alejandroEsc/kubernetes,k82cn/kubernetes,mikebrow/kubernetes,openshift/kubernetes,jsafrane/kubernetes,roberthbailey/kubernetes,deads2k/kubernetes,MikeSpreitzer/kubernetes,mosoft521/kubernetes,jagosan/kubernetes,GulajavaMinistudio/kubernetes,enj/kubernetes,shyamjvs/kubernetes,liggitt/kubernetes,mikedanese/kubernetes,openshift/kubernetes,spzala/kubernetes,mosoft521/kubernetes,jessfraz/kubernetes,jessfraz/kubernetes,monopole/kubernetes,wongma7/kubernetes,kevin-wangzefeng/kubernetes,jsafrane/kubernetes,iameli/kubernetes,dims/kubernetes,mahak/kubernetes,jingxu97/kubernetes,mkumatag/kubernetes,nckturner/kubernetes,iameli/kubernetes,fabriziopandini/kubernetes,MikeSpreitzer/kubernetes,carlory/kubernetes,ping035627/kubernetes,olivierlemasle/kubernetes,ii/kubernetes,liggitt/kubernetes,csrwng/kubernetes,verb/kubernetes,k82/kubernetes,linux-on-ibm-z/kubernetes,dixudx/kubernetes,humblec/kubernetes,lojies/kubernetes,wongma7/kubernetes,sdminonne/kubernetes,jagosan/kubernetes,zhangmingld/kubernetes,kubernetes/kubernetes,zhouhaibing089/kubernetes,BenTheElder/kubernetes,GulajavaMinistudio/kubernetes,hex108/kubernetes,MikeSpreitzer/kubernetes,liggitt/kubernetes,olivierlemasle/kubernetes,k82/kubernetes,monopole/kubernetes,nikhita/kubernetes,thockin/kubernetes,olivierlemasle/kubernetes,monopole/kubernetes,liggitt/kubernetes,li-ang/kubernetes,warmchang/kubernetes,hex108/kubernetes,wongma7/kubernetes,micahhausler/kubernetes,tengqm/kubernetes,mengqiy/kubernetes,tpepper/kubernetes,dixudx/kubernetes,tengqm/kubernetes,zhouhaibing089/kubernetes,ravilr/kubernetes,zhouhaibing089/kubernetes,jingxu97/kubernetes,k82cn/kubernetes,feiskyer/kubernetes,linux-on-ibm-z/kubernetes,olivierlemasle/kubernetes,aledbf/kubernetes,kevin-wangzefeng/kubernetes,liggitt/kubernetes,mikedanese/kubernetes,jackfrancis/kubernetes,jagosan/kubernetes,mikedanese/kubernetes,ping035627/kubernetes,BenTheElder/kubernetes,hex108/kubernetes,verb/kubernetes,alejandroEsc/kubernetes,bparees/kubernetes,rnaveiras/kubernetes,k82/kubernetes,jackfrancis/kubernetes,rnaveiras/kubernetes,monopole/kubernetes,fanzhangio/kubernetes,mkumatag/kubernetes,verb/kubernetes,jagosan/kubernetes,fanzhangio/kubernetes,kubernetes/kubernetes,tpepper/kubernetes,csrwng/kubernetes,cblecker/kubernetes,MikeSpreitzer/kubernetes,dixudx/kubernetes,linux-on-ibm-z/kubernetes,warmchang/kubernetes,roberthbailey/kubernetes,tengqm/kubernetes,PiotrProkop/kubernetes,mikebrow/kubernetes,tpepper/kubernetes,mahak/kubernetes,ravilr/kubernetes,k82cn/kubernetes,openshift/kubernetes,lojies/kubernetes,fabriziopandini/kubernetes,ping035627/kubernetes,matthyx/kubernetes,ping035627/kubernetes,shyamjvs/kubernetes,aledbf/kubernetes,fanzhangio/kubernetes,soltysh/kubernetes,kevin-wangzefeng/kubernetes,chestack/kubernetes,ping035627/kubernetes,lojies/kubernetes,bparees/kubernetes,fanzhangio/kubernetes,GulajavaMinistudio/kubernetes,ravilr/kubernetes,BenTheElder/kubernetes,soltysh/kubernetes,jingxu97/kubernetes