I refactored the LoggerMDC class and created tests (100% code coverage).
Change log for LoggerMDC:
- Moved mappings from a global variable to a private variable within the LoggerMDC class
- Removed need for error suppression (@) in get method, error suppression is not a best practice in PHP
- Changed access to environment vars from @_ENV['var'] to getenv('var'), because $_ENV is not populated on systems where environment variable hashing is disabled in php.ini (by ommiting "E" from the variables_order directive). I encountered this problem just by using the php.ini-recommended which comes with PHP.