michaelckelly / wunderground

A simple wrapper around the Wunderground API for Node
6 stars 4 forks source link

Using 'history' action only seems to return today's weather data. #1

Open doitlikepruett opened 8 years ago

doitlikepruett commented 8 years ago

No matter the date, it returns the same weather data for that location when using the history method. Location param updates the data but again, not the for the date specified.

var wunderground = require("wunderground")('APIKEY')

var query = {
    date:'20100130',
    zip  : '78748' 
};

wunderground.history(query, function(err, weatherData) {
    if(err) {
        alert('Error!') 
    } else {
          weatherData.history.observations.forEach(function(day){
            console.log(day.conds)
          })       
        console.log(weatherData.history.dailysummary)
    }});
michaelckelly commented 8 years ago

@doitlikepruett - I'll take a look at this in the next few days. To be honest, this module has not been updated as of late. Thanks for raising!