#159 finished sorting out portal issues