Little code fixes