Fixing Miscellaneous Bugs