From eb01c8772d6c9aa0bafbc8f0111fab93312078fa Mon Sep 17 00:00:00 2001 From: munja Date: Thu, 3 Feb 2022 18:51:07 +0100 Subject: [PATCH] fix: support for WOFF2 and TTF --- all.sas | 6 +++--- base/mp_streamfile.sas | 6 +++--- sasjs/sasjsconfig.json | 1 + 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/all.sas b/all.sas index 42f16a8..6857b89 100644 --- a/all.sas +++ b/all.sas @@ -10885,15 +10885,15 @@ run; %put %str(ERR)OR: Content Type &contenttype NOT SUPPORTED by &sysmacroname!; %return; %end; -%else %if &contentype=WOFF %then %do; +%else %if &contentype=WOFF or &contentype=WOFF2 or &contentype=TTF %then %do; %if &platform=SASMETA and &streamweb=1 %then %do; data _null_; - rc=stpsrv_header('Content-type','font/woff'); + rc=stpsrv_header('Content-type',"font/%lowcase(&contenttype)"); run; %end; %else %if &platform=SASVIYA %then %do; filename _webout filesrvc parenturi="&SYS_JES_JOB_URI" - contenttype='font/woff'; + contenttype="font/%lowcase(&contenttype)"; %end; %end; %else %if &contentype=XLSX %then %do; diff --git a/base/mp_streamfile.sas b/base/mp_streamfile.sas index 95e3d4f..0c98730 100644 --- a/base/mp_streamfile.sas +++ b/base/mp_streamfile.sas @@ -97,15 +97,15 @@ run; %put %str(ERR)OR: Content Type &contenttype NOT SUPPORTED by &sysmacroname!; %return; %end; -%else %if &contentype=WOFF %then %do; +%else %if &contentype=WOFF or &contentype=WOFF2 or &contentype=TTF %then %do; %if &platform=SASMETA and &streamweb=1 %then %do; data _null_; - rc=stpsrv_header('Content-type','font/woff'); + rc=stpsrv_header('Content-type',"font/%lowcase(&contenttype)"); run; %end; %else %if &platform=SASVIYA %then %do; filename _webout filesrvc parenturi="&SYS_JES_JOB_URI" - contenttype='font/woff'; + contenttype="font/%lowcase(&contenttype)"; %end; %end; %else %if &contentype=XLSX %then %do; diff --git a/sasjs/sasjsconfig.json b/sasjs/sasjsconfig.json index ad14bbd..15e60e6 100644 --- a/sasjs/sasjsconfig.json +++ b/sasjs/sasjsconfig.json @@ -59,6 +59,7 @@ "tests/sas9only" ], "programFolders": [], + "binaryFolders": [], "deployConfig": { "deployServicePack": true, "deployScripts": []