public async isSitePublishingCredentialsEnabled()

in src/appservice-rest/Utilities/AzureAppServiceUtility.ts [105:122]


    public async isSitePublishingCredentialsEnabled(): Promise<boolean>{
        try{
            let scmAuthPolicy: any = await this._appService.getSitePublishingCredentialPolicies();
            core.debug(`Site Publishing Policy check: ${JSON.stringify(scmAuthPolicy)}`);
            if(scmAuthPolicy && scmAuthPolicy.properties.allow) {
                core.debug("Function App does allow SCM access");
                return true;
            }
            else {
                core.debug("Function App does not allow SCM Access");
                return false;
            }
        }
        catch(error){
            core.debug(`Skipping SCM Policy check: ${error}`);
            return false;
        }
    }