added foundation and fixed admin bug