SkinMinerva class has some logic related to the Echo extension (useEcho(), getEchoNotifUser(), getEchoSeenTime(), getFormattedEchoNotificationCount()). Instead of hardcoding Echo-related logic inside Skin class, please provide:
- an interface that defines contract between Skin and Notifications system
- a concrete class that provides Notifications data when Echo is not avaialble
- a concrete class that provides Notifications data when Echo is avaialble (maybe put that in Echo extension ??)
- register proper concrete definition in the ServiceWirings file. The SkinMinerva class should depend only on one service Minerva.NotificationsProvider, and should not know about the Echo extensions.
This code would ideally live in Echo, and be registered via hook. By default where Echo is not installed we show a link to the user's talk page. Echo would be able to replace that button with the Notifications link and register the code.