13-swipe-p2p chat app/index.js
// Checks if there is any non-space character

Checks if there is any non-space character
Checks if there is any non - space character
function hastext(text) {
    if (text.trim().length == 0)
        return false;
    return true;
}
function hastext ( text ) { if ( text . trim ( ) . length == 0 ) return false ; return true ; }
Checks if there is any non-space character
Checks if there is any non - space character