public override void AddShare() { IServerConnectionManager serverConnectionManager = ServiceRegistration.Get <IServerConnectionManager>(); IContentDirectory contentDirectory = GetContentDirectoryService(); contentDirectory.RegisterShare(Share.CreateNewShare(serverConnectionManager.HomeServerSystemId, ChoosenResourcePath, ShareName, MediaCategories)); _serverSharesCache = null; }