Correct missing typeof checks in mqtt#createConnection

Closes #40