Using a number in str_replace causes an exception

When passing in a number as a parameter value to the string replace
function, an exception is raised. Cast the value as a string before
using it in the string replace function.

Change-Id: I38bdc8d97c7d1f9b62f52b0a783bf4d3fde3611a
Closes-Bug: #1250251
Merge "Using a number in str_replace causes an exception"