Ruby if regex help needed -
I'm trying to modify someone's script.
I have managed to modify all but have left a problem I am unable to solve:
disp_status ("\ tSample: # {convert_err (Results ["condition"])} ")
This creates different outputs, however, when the output is" error ", then I get it to work Want to do I'm not sure how to limit it to "error", because it always seems to run the method, it does not matter.
What I tried was:
{Convert_err (result ["condition"])} = ~ / error /
And can anybody help a lot of iterations without any luck?
Ruby does not work in interpolation without double quotes. But using the interpolation here is killing more, just change the line in question like this: <# p,
If # {convert_err (result ["condition"])} = ~ / error
If and it should work! : -)
Comments
Post a Comment