You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							20 lines
						
					
					
						
							451 B
						
					
					
				
			
		
		
	
	
							20 lines
						
					
					
						
							451 B
						
					
					
				| "use strict";
 | |
| 
 | |
| // eslint-disable-next-line node/no-unsupported-features/node-builtins
 | |
| var textDecoder = typeof TextDecoder === 'undefined' ? null : new TextDecoder('utf-8');
 | |
| 
 | |
| function bufferToString(chunk) {
 | |
|   if (typeof chunk === 'string') {
 | |
|     return chunk;
 | |
|   }
 | |
| 
 | |
|   if (textDecoder) {
 | |
|     return textDecoder.decode(chunk);
 | |
|   }
 | |
| 
 | |
|   return chunk.toString();
 | |
| }
 | |
| 
 | |
| exports.bufferToString = bufferToString;
 | |
| //# sourceMappingURL=browser-buffer-decode.js.map
 |