Fixed issues #25 and #26