Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(363)

Side by Side Diff: chrome/test/data/third_party/spaceport/js/util/cacheBust.js

Issue 10134041: Add test data for spaceport benchmark. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 define([ ], function () {
2 var cacheBust = {
3 buster: function buster() {
4 return String(Math.random()).replace(/[^0-9]/g, '');
5 },
6
7 url: function cacheBustUrl(url) {
8 if (/\?/.test(url)) {
9 return url + '&' + cacheBust.buster();
10 } else {
11 return url + '?' + cacheBust.buster();
12 }
13 }
14 };
15
16 return cacheBust;
17 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698