Skip to content
This repository has been archived by the owner on Jan 1, 2023. It is now read-only.

Commit

Permalink
Forecast.io brandname changed to Dark Sky
Browse files Browse the repository at this point in the history
  • Loading branch information
ofalvai committed Sep 22, 2016
1 parent 2bff156 commit ab88c3a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@
</div>
<a id="forecast-link" target="_blank">
<div class="panel-footer">
<span class="pull-left">Details on Forecast.io</span>
<span class="pull-left">Details on Dark Sky</span>
<span class="pull-right"><i class="fa fa-arrow-circle-right"></i></span>
<div class="clearfix"></div>
</div>
Expand Down
12 changes: 6 additions & 6 deletions public/javascripts/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ var config = {
unit: 'celsius',

/**
* Coordinates for getting outside weather data from forecast.io
* Coordinates for getting outside weather data from darksky.net
* By default, location is determined by HTML5 geolocation,
* but as a fallback it relies on manual coordinates.
*
Expand All @@ -40,8 +40,8 @@ var config = {
},

/**
* Forecast.io API key.
* Please don't abuse this. Be a good guy and request your own at http://developer.forecast.io
* Dark Sky API key.
* Please don't abuse this. Be a good guy and request your own at https://darksky.net/dev
*/
APIKey: '262d0436a1b2d47e7593f0bb41491b64',

Expand Down Expand Up @@ -420,11 +420,11 @@ function getLocation() {

function loadOutsideWeather() {
if(!config.APIKey) {
displayError('No Forecast.io API key, unable to get outside weather data.', '#error-container');
displayError('No Dark Sky API key, unable to get outside weather data.', '#error-container');
return;
}

$.getJSON('https://api.forecast.io/forecast/' +
$.getJSON('https://api.darksky.net/forecast/' +
config.APIKey + '/' +
config.latitude + ',' +
config.longitude +
Expand All @@ -434,7 +434,7 @@ function loadOutsideWeather() {
$('#curr-hum-outside').text((json.currently.humidity*100).toFixed() + '%');

$('#forecast-summary').text(json.hourly.summary);
$('#forecast-link').attr('href', 'http://forecast.io/#/f/' +
$('#forecast-link').attr('href', 'http://darksky.net/#/f/' +
config.latitude + ',' + config.longitude);
});
}
Expand Down

0 comments on commit ab88c3a

Please sign in to comment.