Browse code

Fixed typo in BuildRequest field name

Michal Fojtik authored on 2015/05/30 16:13:18
Showing 6 changed files
... ...
@@ -407,8 +407,8 @@ type BuildRequest struct {
407 407
 	// Revision is the information from the source for a specific repo snapshot.
408 408
 	Revision *SourceRevision `json:"revision,omitempty"`
409 409
 
410
-	// TriggedByImage is the image name that triggered this build.
411
-	TriggedByImage string
410
+	// TriggeredByImage is the image name that triggered this build.
411
+	TriggeredByImage string
412 412
 }
413 413
 
414 414
 // BuildLogOptions is the REST options for a build log
... ...
@@ -391,8 +391,8 @@ type BuildRequest struct {
391 391
 	// Revision is the information from the source for a specific repo snapshot.
392 392
 	Revision *SourceRevision `json:"revision,omitempty"`
393 393
 
394
-	// TriggedByImage is the image name that triggered this build.
395
-	TriggedByImage string `json:"triggedByImage,omitempty"`
394
+	// TriggeredByImage is the image name that triggered this build.
395
+	TriggeredByImage string `json:"triggedByImage,omitempty"`
396 396
 }
397 397
 
398 398
 // BuildLogOptions is the REST options for a build log
... ...
@@ -456,8 +456,8 @@ type BuildRequest struct {
456 456
 	// Revision is the information from the source for a specific repo snapshot.
457 457
 	Revision *SourceRevision `json:"revision,omitempty"`
458 458
 
459
-	// TriggedByImage is the image name that triggered this build.
460
-	TriggedByImage string `json:"triggedByImage,omitempty"`
459
+	// TriggeredByImage is the image name that triggered this build.
460
+	TriggeredByImage string `json:"triggedByImage,omitempty"`
461 461
 }
462 462
 
463 463
 // BuildLogOptions is the REST options for a build log
... ...
@@ -391,8 +391,8 @@ type BuildRequest struct {
391 391
 	// Revision is the information from the source for a specific repo snapshot.
392 392
 	Revision *SourceRevision `json:"revision,omitempty"`
393 393
 
394
-	// TriggedByImage is the image name that triggered this build.
395
-	TriggedByImage string `json:"triggedByImage,omitempty"`
394
+	// TriggeredByImage is the image name that triggered this build.
395
+	TriggeredByImage string `json:"triggedByImage,omitempty"`
396 396
 }
397 397
 
398 398
 // BuildLogOptions is the REST options for a build log
... ...
@@ -110,7 +110,7 @@ func (c *ImageChangeController) HandleImageRepo(repo *imageapi.ImageStream) erro
110 110
 				ObjectMeta: kapi.ObjectMeta{
111 111
 					Name: config.Name,
112 112
 				},
113
-				TriggedByImage: triggeredImage,
113
+				TriggeredByImage: triggeredImage,
114 114
 			}
115 115
 			if _, err := c.BuildConfigInstantiator.Instantiate(config.Namespace, request); err != nil {
116 116
 				if kerrors.IsConflict(err) {
... ...
@@ -135,13 +135,13 @@ func (g *BuildGenerator) Instantiate(ctx kapi.Context, request *buildapi.BuildRe
135 135
 		return nil, err
136 136
 	}
137 137
 
138
-	if len(request.TriggedByImage) > 0 {
138
+	if len(request.TriggeredByImage) > 0 {
139 139
 		for _, trigger := range bc.Triggers {
140 140
 			if trigger.Type != buildapi.ImageChangeBuildTriggerType {
141 141
 				continue
142 142
 			}
143 143
 
144
-			trigger.ImageChange.LastTriggeredImageID = request.TriggedByImage
144
+			trigger.ImageChange.LastTriggeredImageID = request.TriggeredByImage
145 145
 		}
146 146
 	}
147 147