link: extract keg-only check into a helper method
link: extract keg-only check into a helper method

amar-laksh/brew_sudo,muellermartin/dist,vitorgalvao/brew,nandub/brew,reitermarkus/brew,alyssais/brew,bfontaine/brew,tonyg/homebrew,claui/brew,DomT4/brew,mahori/brew,staticfloat/brew,palxex/brew,gordonmcshane/homebrew,nandub/brew,mgrimes/brew,reelsense/brew,staticfloat/brew,EricFromCanada/brew,MikeMcQuaid/brew,konqui/brew,JCount/brew,AnastasiaSulyagina/brew,sjackman/homebrew,Linuxbrew/brew,hanxue/linuxbrew,pseudocody/brew,toonetown/homebrew,amar-laksh/brew_sudo,konqui/brew,hanxue/linuxbrew,Linuxbrew/brew,sjackman/homebrew,claui/brew,mgrimes/brew,gregory-nisbet/brew,reelsense/brew,nandub/brew,DomT4/brew,konqui/brew,toonetown/homebrew,gordonmcshane/homebrew,muellermartin/dist,pseudocody/brew,JCount/brew,sjackman/homebrew,rwhogg/brew,pseudocody/brew,jmsundar/brew,Linuxbrew/brew,hanxue/linuxbrew,vitorgalvao/brew,JCount/brew,tonyg/homebrew,gordonmcshane/homebrew,Homebrew/brew,rwhogg/brew,bfontaine/brew,rwhogg/brew,nandub/brew,DomT4/brew,vitorgalvao/brew,AnastasiaSulyagina/brew,claui/brew,mahori/brew,maxim-belkin/brew,alyssais/brew,palxex/brew,gregory-nisbet/brew,zmwangx/brew,jmsundar/brew,vitorgalvao/brew,aw1621107/brew,gregory-nisbet/brew,MikeMcQuaid/brew,Homebrew/brew,AnastasiaSulyagina/brew,Linuxbrew/brew,mistydemeo/homebrew,bfontaine/brew,reitermarkus/brew,tonyg/homebrew,mistydemeo/homebrew,mahori/brew,mistydemeo/homebrew,reitermarkus/brew,sjackman/homebrew,reelsense/brew,MikeMcQuaid/brew,muellermartin/dist,EricFromCanada/brew,staticfloat/brew,aw1621107/brew,maxim-belkin/brew,MikeMcQuaid/brew,DomT4/brew,ilovezfs/brew,jmsundar/brew,reitermarkus/brew,amar-laksh/brew_sudo,EricFromCanada/brew,toonetown/homebrew,JCount/brew,palxex/brew,mahori/brew,mgrimes/brew,alyssais/brew,zmwangx/brew,zmwangx/brew,claui/brew,Homebrew/brew,Homebrew/brew,konqui/brew,EricFromCanada/brew,ilovezfs/brew,maxim-belkin/brew,ilovezfs/brew,aw1621107/brew