lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


I'm doing something wrong.

(I am converting an api call into a local file call. It should just read the entire 70K response (in json format) into the var. I parse it out later.)

This hangs my app:

function file_getdata()
	local data_file_path = gre.SCRIPT_ROOT .. "/myfile.json"
	local f = io.open(data_file_path)
	f = io.read("*all")
	f = io.close()
	return f
end




Dave Collins
Front-End Engineer
Mercatus Technologies Inc.
60 Adelaide Street East, Suite 700
Toronto ON M5C 3E4
T  416 603 3406 x 298
F  416 603 1790

dave.collins@mercatustechnologies.com
www.mercatustechnologies.com