fixing a few issues