0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-24 14:12:40 +00:00

Don't save style tab if user never put anything in it

This commit is contained in:
Trevor Buckner
2021-06-24 23:29:01 -04:00
parent e2280197b9
commit e07bb1b3c2
4 changed files with 18 additions and 25 deletions

View File

@@ -20,10 +20,12 @@ const getGoodBrewTitle = (text)=>{
};
const mergeBrewText = (text, style)=>{
text = `\`\`\`css\n` +
`${style}\n` +
`\`\`\`\n\n` +
`${text}`;
if(typeof style !== 'undefined') {
text = `\`\`\`css\n` +
`${style}\n` +
`\`\`\`\n\n` +
`${text}`;
}
return text;
};