Changeset 130306 in webkit


Ignore:
Timestamp:
Oct 3, 2012, 11:15:09 AM (13 years ago)
Author:
ojan@chromium.org
Message:

Get rid of warning about non-existant platform name when loading garden-o-matic
https://bugs.webkit.org/show_bug.cgi?id=98282

Reviewed by Adam Barth.

If you loaded without a platform query parameter we'd return "null" as the platform name
instead of null.

  • BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/base.js:
  • BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/base_unittests.js:
Location:
trunk/Tools
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/base.js

    r120648 r130306  
    439439base.getURLParameter = function(name)
    440440{
    441     return decodeURI(
    442         (RegExp(name + '=' + '(.+?)(&|$)').exec(location.search)||[,null])[1]
    443     );
    444 }
    445 
     441    var match = RegExp(name + '=' + '(.+?)(&|$)').exec(location.search);
     442    if (!match)
     443        return null;
     444    return decodeURI(match[1])
     445}
    446446
    447447base.underscoredBuilderName = function(builderName)
  • trunk/Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/base_unittests.js

    r111796 r130306  
    461461    time.setDate(time.getDate() - 998);
    462462    equals(base.relativizeTime(time), "1000 days ago");
    463 })
     463});
     464
     465test("getURLParameter", 1, function() {
     466    ok(!base.getURLParameter('non-existant'));
     467});
    464468
    465469})();
  • trunk/Tools/ChangeLog

    r130283 r130306  
     12012-10-03  Ojan Vafai  <ojan@chromium.org>
     2
     3        Get rid of warning about non-existant platform name when loading garden-o-matic
     4        https://bugs.webkit.org/show_bug.cgi?id=98282
     5
     6        Reviewed by Adam Barth.
     7
     8        If you loaded without a platform query parameter we'd return "null" as the platform name
     9        instead of null.
     10        * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/base.js:
     11        * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/base_unittests.js:
     12
    1132012-10-03  Balazs Kelemen  <kbalazs@webkit.org>
    214
Note: See TracChangeset for help on using the changeset viewer.