Code cleanup

This commit is contained in:
Sahat Yalkabov
2013-12-08 01:17:12 -05:00
parent ba75d67688
commit 58805c678d
4 changed files with 13 additions and 9 deletions

1
app.js
View File

@ -71,6 +71,7 @@ app.get('/api/nyt', api.getNewYorkTimes);
app.get('/api/twilio', api.getTwilio);
app.get('/api/etsy', api.getEtsy);
app.get('/api/twitter', passportConf.ensureAuthenticated, api.getTwitter);
app.get('/api/aviary', passportConf.ensureAuthenticated, api.getAviary);
app.get('/contact', contact.getContact);
app.post('/contact', contact.postContact);

View File

@ -25,7 +25,6 @@ exports.getApi = function(req, res) {
*/
exports.getFoursquare = function(req, res) {
var token = _.findWhere(req.user.tokens, { kind: 'foursquare' });
if (!token) {
return res.render('api/unauthorized', {
title: 'Foursquare API',
@ -33,7 +32,6 @@ exports.getFoursquare = function(req, res) {
user: req.user
});
}
async.parallel({
trendingVenues: function(callback) {
var geo = geoip.lookup('4.17.136.0');
@ -176,6 +174,13 @@ exports.getTwilio = function(req, res) {
};
/**
* GET /api/aviary
*/
exports.getAviary = function(req, res) {
};
exports.getEtsy = function(req, res) {
};

View File

@ -4,6 +4,8 @@ block content
h2 API Browser
ul.list-unstyled.lead
li
a(href='/api/aviary') Aviary
li
a(href='/api/etsy') Etsy
li
@ -24,5 +26,3 @@ block content
a(href='/api/twilio') Twilio
li
a(href='/api/scraping') Web Scraping

View File

@ -17,8 +17,6 @@ block content
| API Endpoints
h3.text-primary #{blog.name}'s blog
h4 Blog Stats
p
.btn.btn-xs.btn-primary-outline
i.fa.fa-file-text-o
| #{blog.posts} posts