got it to work, added more secure code