Skip to content

Commit

Permalink
// Prevent javascript error
Browse files Browse the repository at this point in the history
  • Loading branch information
jnadaud committed Mar 10, 2014
1 parent ff75686 commit e183972
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/admin-dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ function getBlogRss() {
},
dataType: 'json',
success : function(jsonData) {
if (!jsonData.has_errors) {
if (typeof jsonData !== 'undefined' && jsonData !== null && !jsonData.has_errors) {
for (var article in jsonData.rss) {
var article_html = '<article><h4><a href="'+jsonData.rss[article].link+'">'+jsonData.rss[article].title+'</a></h4><span class="dash-news-date text-muted">'+jsonData.rss[article].date+'</span><p>'+jsonData.rss[article].short_desc+' <a href="'+jsonData.rss[article].link+'">'+read_more+'</a><p></article><hr/>';
$('.dash_news .dash_news_content').append(article_html);
Expand Down

0 comments on commit e183972

Please sign in to comment.