Added checks against input

This stops `Cannot call method 'replace' of undefined` errors when non strings are passed in.

Basically this would stop the need for users to have to manually check that a value is a string before passing it in.
Example is our particular use-case where an address field is optional and may be undefined.

Before:

    ...

    address.line_1 = capitalize.words(address.line_1);

    if (address.line_2 && (typeof address.line_2 === "string")) {
        address.line_2 = capitalize.words(address.line_2);
    }


After:

    ...

    address.line_1 = capitalize.words(address.line_1);
    address.line_2 = capitalize.words(address.line_2);

    ...