Compare commits
3 Commits
feat/add-n
...
fix/regres
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
da4b2e68ab | ||
|
|
5557b1bcba | ||
|
|
f4b5f98a44 |
@@ -84,11 +84,6 @@ export const SetHookDialog: React.FC<{ account: IAccount }> = ({ account }) => {
|
||||
snap.files?.[snap.active]?.name?.split(".")?.[0] || ""
|
||||
);
|
||||
const calculateHashedValue = useCallback(async () => {
|
||||
console.log(
|
||||
"-->",
|
||||
namespace,
|
||||
snap.files?.[snap.active]?.name?.split(".")?.[0]
|
||||
);
|
||||
const hashedVal = await sha256(namespace);
|
||||
setHashedNamespace(hashedVal.toUpperCase());
|
||||
}, [namespace]);
|
||||
|
||||
@@ -28,11 +28,6 @@ export const fetchFiles = (gistId: string) => {
|
||||
const resHeader = await fetch(`${process.env.NEXT_PUBLIC_COMPILE_API_BASE_URL}/api/header-files`);
|
||||
if (resHeader.ok) {
|
||||
resHeaderJson = await resHeader.json();
|
||||
}
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
}
|
||||
|
||||
const files = {
|
||||
...res.data.files,
|
||||
'hookapi.h': res.data.files?.['hookapi.h'] || { filename: 'hookapi.h', content: resHeaderJson.hookapi, language: 'C' },
|
||||
@@ -40,6 +35,12 @@ export const fetchFiles = (gistId: string) => {
|
||||
'sfcodes.h': res.data.files?.['sfcodes.h'] || { filename: 'sfcodes.h', content: resHeaderJson.sfcodes, language: 'C' },
|
||||
};
|
||||
res.data.files = files;
|
||||
}
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
}
|
||||
|
||||
|
||||
|
||||
return res;
|
||||
// If you want to load templates from GIST instad, uncomment the code below and comment the code above.
|
||||
|
||||
Reference in New Issue
Block a user