mirror of
				https://github.com/TeaOSLab/EdgeAPI.git
				synced 2025-11-04 07:50:25 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			19 lines
		
	
	
		
			307 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			19 lines
		
	
	
		
			307 B
		
	
	
	
		
			Go
		
	
	
	
	
	
package models
 | 
						|
 | 
						|
import (
 | 
						|
	"encoding/json"
 | 
						|
	"github.com/iwind/TeaGo/logs"
 | 
						|
)
 | 
						|
 | 
						|
func (this *RegionCountry) DecodeCodes() []string {
 | 
						|
	if len(this.Codes) == 0 {
 | 
						|
		return []string{}
 | 
						|
	}
 | 
						|
	result := []string{}
 | 
						|
	err := json.Unmarshal([]byte(this.Codes), &result)
 | 
						|
	if err != nil {
 | 
						|
		logs.Error(err)
 | 
						|
	}
 | 
						|
	return result
 | 
						|
}
 |