mirror of
				https://github.com/taigrr/yq
				synced 2025-01-18 04:53:17 -08:00 
			
		
		
		
	Dont use pointer for env prefs (avoid nil)
This commit is contained in:
		
							parent
							
								
									0318c80d33
								
							
						
					
					
						commit
						54723c1a36
					
				| @ -183,7 +183,7 @@ func stringValue(wrapped bool) lex.Action { | ||||
| func envOp(strenv bool) lex.Action { | ||||
| 	return func(s *lex.Scanner, m *machines.Match) (interface{}, error) { | ||||
| 		value := string(m.Bytes) | ||||
| 		preferences := &envOpPreferences{} | ||||
| 		preferences := envOpPreferences{} | ||||
| 
 | ||||
| 		if strenv { | ||||
| 			// strenv( ) | ||||
|  | ||||
| @ -19,7 +19,7 @@ func envOperator(d *dataTreeNavigator, matchMap *list.List, expressionNode *Expr | ||||
| 
 | ||||
| 	rawValue := os.Getenv(envName) | ||||
| 
 | ||||
| 	preferences := expressionNode.Operation.Preferences.(*envOpPreferences) | ||||
| 	preferences := expressionNode.Operation.Preferences.(envOpPreferences) | ||||
| 
 | ||||
| 	var node *yaml.Node | ||||
| 	if preferences.StringValue { | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user