mirror of
https://github.com/DigiLive/mushroom-strategy.git
synced 2025-08-04 20:14:28 +02:00
Fix unneeded domain check
Method createCardConfigurations checks for domain `Home` which will not evaluatie to `true` because this domain overrides the method anyway.
This commit is contained in:
@@ -53,13 +53,6 @@ abstract class AbstractView {
|
||||
* Create the configuration of the cards to include in the view.
|
||||
*/
|
||||
protected async createCardConfigurations(): Promise<LovelaceCardConfig[]> {
|
||||
if (this.domain === 'home') {
|
||||
// The home domain should override this method because it hasn't entities of its own.
|
||||
// The method override creates its own configurations for cards to show at the home view.
|
||||
|
||||
return [];
|
||||
}
|
||||
|
||||
const viewCards: LovelaceCardConfig[] = [];
|
||||
const domainEntities = new RegistryFilter(Registry.entities).whereDomain(this.domain).toList();
|
||||
const moduleName = sanitizeClassName(this.domain + 'Card');
|
||||
|
Reference in New Issue
Block a user