HEX
Server: nginx/1.18.0
System: Linux m1-ws1-ams3 5.4.0-148-generic #165-Ubuntu SMP Tue Apr 18 08:53:12 UTC 2023 x86_64
User: root (0)
PHP: 7.4.33
Disabled: NONE
Upload Files
File: /opt/aphex/sites/tomtomsummer.com/wp-content/plugins/wpforms-lite/src/Helpers/File.php
<?php

namespace WPForms\Helpers;

/**
 * Class File.
 *
 * @since 1.6.5
 */
class File {

	/**
	 * Remove UTF-8 BOM signature if it presents.
	 *
	 * @since 1.6.5
	 *
	 * @param string $string String to process.
	 *
	 * @return string
	 */
	public static function remove_utf8_bom( $string ) {

		if ( strpos( bin2hex( $string ), 'efbbbf' ) === 0 ) {
			$string = substr( $string, 3 );
		}

		return $string;
	}
}