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

Unified Diff: chrome/common/extensions/docs/server2/samples_data_source.py

Issue 10894049: Make links to samples and re-enable sample list for api references. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: patch'd Created 8 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/docs/server2/samples_data_source.py
diff --git a/chrome/common/extensions/docs/server2/samples_data_source.py b/chrome/common/extensions/docs/server2/samples_data_source.py
index 9fa389fd73e31c2515725958a31dbdb9acab91d8..83707990f993b2986cd662d9f912abf0f672d73c 100644
--- a/chrome/common/extensions/docs/server2/samples_data_source.py
+++ b/chrome/common/extensions/docs/server2/samples_data_source.py
@@ -2,6 +2,7 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
+import hashlib
import json
import logging
import re
@@ -137,6 +138,7 @@ class SamplesDataSource(object):
icon_path = icon_base + '/' + manifest_data['icon']
manifest_data.update({
'icon': icon_path,
+ 'id': hashlib.md5(url).hexdigest(),
'download_url': download_url,
'url': url,
'files': [f.replace(sample_path + '/', '') for f in sample_files],

Powered by Google App Engine
This is Rietveld 408576698