|
@@ -455,8 +455,9 @@ if __name__ == '__main__':
|
|
|
mysearch = Search() ## Search used to take county as parameter, so this loop would work. Now Search class contains list. loop must occur in getmlsdata module
|
|
mysearch = Search() ## Search used to take county as parameter, so this loop would work. Now Search class contains list. loop must occur in getmlsdata module
|
|
|
mydata = gmls.getmlsdata(mysearch, county)
|
|
mydata = gmls.getmlsdata(mysearch, county)
|
|
|
|
|
|
|
|
- for listing in mydata:
|
|
|
|
|
- myresults.append(listing)
|
|
|
|
|
|
|
+ if mydata: #Avoids a crash is there is no data
|
|
|
|
|
+ for listing in mydata:
|
|
|
|
|
+ myresults.append(listing)
|
|
|
|
|
|
|
|
# print(len(myresults))
|
|
# print(len(myresults))
|
|
|
# print(myresults[0].address)
|
|
# print(myresults[0].address)
|