MCPcopy Create free account
hub / github.com/unconed/TermKit / fixInputString

Function fixInputString

HTML/external/syntaxhighlighter_3.0.83/src/shCore.js:915–926  ·  view source on GitHub ↗

* Performs various string fixes based on configuration.

(str)

Source from the content-addressed store, hash-verified

913 * Performs various string fixes based on configuration.
914 */
915function fixInputString(str)
916{
917 var br = /<br\s*\/?>|&lt;br\s*\/?&gt;/gi;
918
919 if (sh.config.bloggerMode == true)
920 str = str.replace(br, '\n');
921
922 if (sh.config.stripBrs == true)
923 str = str.replace(br, '');
924
925 return str;
926};
927
928/**
929 * Removes all white space at the begining and end of a string.

Callers 1

unindentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected