Implemented changes from 8c4d2c43672624f87dc0c9dcbb91bf6b7ef2cd8b in other parts of the application.
Closes #19.