Fixed a bug in logger.ts
Switch statement 'success' was instead written as 'logFunctionName'