It must function correctly , Check it like
<script type="text/javascript">
var a = '1716e362-5afe-4c80-9fff-880aaf109638';
var b = '1716e362-5afe-4c80-9fff-880aaf109638';
if(a==b)
{
alert("true");
}
else
{
alert("false");
}
</script>
If alerts true than same else alerts false
Hope it helps