This commit is contained in:
William Knauss
2014-06-05 20:34:08 -04:00
parent 65061046bd
commit 936b6f4a50

View File

@@ -391,24 +391,24 @@ class parseCSV {
* @return [bool]
*/
public function parse ($input = null, $offset = null, $limit = null, $conditions = null) {
if ( $input === null ) {
if (is_null($input)) {
$input = $this->file;
}
if ( !empty($input) ) {
if ( $offset !== null ) {
if (!empty($input)) {
if (!is_null($offset)) {
$this->offset = $offset;
}
if ($limit !== null ) {
if (!is_null($limit)) {
$this->limit = $limit;
}
if ( !is_null($conditions) ) {
if (!is_null($conditions)) {
$this->conditions = $conditions;
}
if ( is_readable($input) ) {
if (is_readable($input)) {
$this->data = $this->parse_file($input);
}
else {
@@ -416,7 +416,7 @@ class parseCSV {
$this->data = $this->parse_string();
}
if ( $this->data === false ) {
if ($this->data === false) {
return false;
}
}