Adding more functionality and fixes.