mirror of
https://github.com/opelly27/streetmerchant.git
synced 2026-05-20 14:37:41 +00:00
feat(docs): add mkdocs
This commit is contained in:
+17
-11
@@ -20,19 +20,25 @@ export function playSound() {
|
||||
if (config.notifications.playSound && player.player !== null) {
|
||||
logger.debug('↗ playing sound');
|
||||
|
||||
fs.access(config.notifications.playSound, fs.constants.F_OK, (error) => {
|
||||
if (error) {
|
||||
logger.error(`✖ error opening sound file: ${error.message}`);
|
||||
return;
|
||||
}
|
||||
|
||||
player.play(config.notifications.playSound, (error: Error) => {
|
||||
fs.access(
|
||||
config.notifications.playSound,
|
||||
fs.constants.F_OK,
|
||||
(error) => {
|
||||
if (error) {
|
||||
logger.error("✖ couldn't play sound", error);
|
||||
logger.error(
|
||||
`✖ error opening sound file: ${error.message}`
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
logger.info('✔ played sound');
|
||||
});
|
||||
});
|
||||
player.play(config.notifications.playSound, (error: Error) => {
|
||||
if (error) {
|
||||
logger.error("✖ couldn't play sound", error);
|
||||
}
|
||||
|
||||
logger.info('✔ played sound');
|
||||
});
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user