Permalink
Browse files

Fetch text data by default (enable switch back and forth with fs)

  • Loading branch information...
mde committed Jan 28, 2014
1 parent 8dcb0b4 commit 01212e14505e01bdce26bb2c223f65f74e8e4859
Showing with 2 additions and 0 deletions.
  1. +2 −0 site/app/controllers/main.js
@@ -55,6 +55,7 @@ var Main = function () {
opts = {
url: URL_PREFIX + p
, headers: {'User-Agent': 'GeddyJS documentation site'}
+ , dataType: 'txt'
};
geddy.request(opts, function (err, data) {
if (err) { throw err; }
@@ -67,6 +68,7 @@ var Main = function () {
// Parse the JSON data and return as JS obj
, getTopicsForDocType = function (docType, callback) {
fetch(docType + '/topics.json', function (data) {
+ console.log(data);
callback(JSON.parse(data));
});
}

0 comments on commit 01212e1

Please sign in to comment.