Commit cc5e7a15 by Urvil Shah

Add the guard on the wrapping content.

parent 28c35737
Pipeline #7389 passed with stages
in 23 minutes 17 seconds
...@@ -171,7 +171,11 @@ namespace Mobile.Search.Web.Controllers ...@@ -171,7 +171,11 @@ namespace Mobile.Search.Web.Controllers
{ {
to_replace= String.Format("{{{{WrapAdvertiserUnsubscribeUrl('{0}')}}}}", m.Groups[1]); to_replace= String.Format("{{{{WrapAdvertiserUnsubscribeUrl('{0}')}}}}", m.Groups[1]);
} }
value = value.Replace(m.Groups[1].Value, to_replace); if(m.Groups[1].Value.Count()>0)
{
value = value.Replace(m.Groups[1].Value, to_replace);
}
} }
m = m.NextMatch(); m = m.NextMatch();
...@@ -208,7 +212,8 @@ namespace Mobile.Search.Web.Controllers ...@@ -208,7 +212,8 @@ namespace Mobile.Search.Web.Controllers
catch (Exception x) catch (Exception x)
{ {
Log.Error("Edit: Error " + x); Log.Error("Edit: Error " + x);
return View(); return Json(new { status = "Failed" });
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment