added filter to ensure login