@@ -101,23 +101,23 @@ func (s *Service) AppBrickInstanceDetails(a *app.ArduinoApp, brickID string) (Br
101101 return BrickInstanceDetails {}, fmt .Errorf ("brick %s not added in the app" , brickID )
102102 }
103103
104- variables := make (map [string ]BrickVariable , len (brick .Variables ))
104+ variables := make (map [string ]BrickInstanceVariable , len (brick .Variables ))
105105 for _ , v := range brick .Variables {
106- variables [v .Name ] = BrickVariable {
107- DefaultValue : v .DefaultValue ,
108- Description : v .Description ,
109- Required : v .IsRequired (),
106+ variables [v .Name ] = BrickInstanceVariable {
107+ Value : v .DefaultValue ,
108+ Description : v .Description ,
109+ Required : v .IsRequired (),
110110 }
111111 }
112112 // Add/Update the variables with the ones from the app descriptor
113113 appVars := a .Descriptor .Bricks [brickIndex ].Variables
114114 for varName , appValue := range appVars {
115115 if v , ok := variables [varName ]; ok {
116- v .DefaultValue = appValue
116+ v .Value = appValue
117117 variables [varName ] = v
118118 } else {
119- variables [varName ] = BrickVariable {
120- DefaultValue : appValue ,
119+ variables [varName ] = BrickInstanceVariable {
120+ Value : appValue ,
121121 }
122122 }
123123 }
0 commit comments