Browse Source

bug():save mqtt yaml (#502)

Co-authored-by: EMqmyd <mayuedong@emx.io>
EMQmyd 4 years atrás
parent
commit
a6dda19905
1 changed files with 2 additions and 1 deletions
  1. 2 1
      plugins/sourceMeta.go

+ 2 - 1
plugins/sourceMeta.go

@@ -384,7 +384,8 @@ func (this *sourceProperty) saveCf(pluginName string) error {
 	}
 
 	dir := path.Join(confDir, "sources")
-	if "mqtt_source" == pluginName {
+	if "mqtt" == pluginName {
+		pluginName = "mqtt_source"
 		dir = confDir
 	}
 	filePath := path.Join(dir, pluginName+".yaml")