~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to www/media/common/util.js

  • Committer: mattgiuca
  • Date: 2008-01-15 05:56:14 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:232
common/util.js: Fixed urlencode_path - empty paths no longer get a mysterious
slash.

Show diffs side-by-side

added added

removed removed

Lines of Context:
334
334
    for (var i=0; i<split.length; i++)
335
335
        split[i] = encodeURIComponent(split[i]);
336
336
    path = path_join.apply(null, split);
337
 
    if (split[0] == "") path = "/" + path;
 
337
    if (split[0] == "" && split.length > 1) path = "/" + path;
338
338
    return path;
339
339
}
340
340