Added commands add-/remove-media and handling path to realpath conversions in message handlers