Fix returning bad variable

Change-Id: Ie3bb0a86987679f7b516c7251e2254b9a0a710e0