From 2ab7625bb56d338f4a5f5c2a7c5f096c9890d5cd Mon Sep 17 00:00:00 2001 From: William Knauss Date: Tue, 13 May 2014 18:24:31 -0400 Subject: [PATCH] _rfile readability --- parsecsv.lib.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/parsecsv.lib.php b/parsecsv.lib.php index 4ff7140..eebf887 100644 --- a/parsecsv.lib.php +++ b/parsecsv.lib.php @@ -1047,16 +1047,19 @@ class parseCSV { /** * Read local file + * + * @access public * @param file local filename * @return Data from file, or false on failure */ - function _rfile ($file = null) { + public function _rfile ($file = null) { if ( is_readable($file) ) { if ( !($fh = fopen($file, 'r')) ) return false; $data = fread($fh, filesize($file)); fclose($fh); return $data; } + return false; } @@ -1068,9 +1071,10 @@ class parseCSV { * @param string data to write to file * @param mode fopen() mode * @param lock flock() mode + * * @return true or false */ - function _wfile ($file, $string = '', $mode = 'wb', $lock = 2) { + public function _wfile ($file, $string = '', $mode = 'wb', $lock = 2) { if ( $fp = fopen($file, $mode) ) { flock($fp, $lock); $re = fwrite($fp, $string);