Skip to content

Commit

Permalink
Fix PredictiveUnitState image name and version (#562)
Browse files Browse the repository at this point in the history
  • Loading branch information
sasvaritoni committed May 17, 2019
1 parent 37780d6 commit 6a52b3e
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,11 @@ public PredictiveUnitState(

if (containersMap.containsKey(name)){
this.image = containersMap.get(name).getImage();
if (image.contains(":"))
int i = image.lastIndexOf(":");
if (i >= 0)
{
String[] parts = image.split(":");
this.imageName = parts[0];
this.imageVersion = parts[1];
this.imageName = StringUtils.substring(image, 0, i);
this.imageVersion = StringUtils.substring(image, i+1);
}
else
{
Expand Down

0 comments on commit 6a52b3e

Please sign in to comment.