added fib, fixed some bugs