mirror of
				https://github.com/TeaOSLab/EdgeAPI.git
				synced 2025-11-04 16:00:24 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			18 lines
		
	
	
		
			313 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
		
			313 B
		
	
	
	
		
			Go
		
	
	
	
	
	
package models
 | 
						|
 | 
						|
import "encoding/json"
 | 
						|
 | 
						|
func (this *MetricChart) DecodeIgnoredKeys() []string {
 | 
						|
	if len(this.IgnoredKeys) == 0 {
 | 
						|
		return []string{}
 | 
						|
	}
 | 
						|
 | 
						|
	var result = []string{}
 | 
						|
	err := json.Unmarshal([]byte(this.IgnoredKeys), &result)
 | 
						|
	if err != nil {
 | 
						|
		// 这里忽略错误
 | 
						|
		return result
 | 
						|
	}
 | 
						|
	return result
 | 
						|
}
 |