Selaa lähdekoodia

fix(desktop): remove overly-aggressive feature flag check (#11748)

Milas Bowman 1 vuosi sitten
vanhempi
sitoutus
fd532a37e7
2 muutettua tiedostoa jossa 3 lisäystä ja 7 poistoa
  1. 0 4
      internal/experimental/experimental.go
  2. 3 3
      pkg/compose/desktop.go

+ 0 - 4
internal/experimental/experimental.go

@@ -71,10 +71,6 @@ func (s *State) NavBar() bool {
 	return s.determineFeatureState("ComposeNav")
 }
 
-func (s *State) AutoFileShares() bool {
-	return s.determineFeatureState("ComposeAutoFileShares")
-}
-
 func (s *State) determineFeatureState(name string) bool {
 	if s == nil || !s.active || s.desktopValues == nil {
 		return false

+ 3 - 3
pkg/compose/desktop.go

@@ -33,12 +33,12 @@ func (s *composeService) SetExperiments(experiments *experimental.State) {
 }
 
 func (s *composeService) manageDesktopFileSharesEnabled(ctx context.Context) bool {
-	// there's some slightly redundancy here to avoid fetching the config if
-	// we can already tell the feature state - in practice, we
-	if !s.isDesktopIntegrationActive() || !s.experiments.AutoFileShares() {
+	if !s.isDesktopIntegrationActive() {
 		return false
 	}
 
+	// synchronized file share support in Docker Desktop is dependent upon
+	// a variety of factors (settings, OS, etc), which this endpoint abstracts
 	fileSharesConfig, err := s.desktopCli.GetFileSharesConfig(ctx)
 	if err != nil {
 		logrus.Debugf("Failed to retrieve file shares config: %v", err)