summaryrefslogtreecommitdiff
path: root/it_dbi_postgres.class
diff options
context:
space:
mode:
authorNathan Gass2020-09-03 15:10:08 +0200
committerNathan Gass2020-09-03 15:10:08 +0200
commit0a1feb7c54e7167b0479fe116e0062017d9496b8 (patch)
tree360b83858239311ae85b611d64d2b9a06353559a /it_dbi_postgres.class
parent75bbc82ca87fde88e5b9a8c902554a70831eb224 (diff)
downloaditools-0a1feb7c54e7167b0479fe116e0062017d9496b8.tar.gz
itools-0a1feb7c54e7167b0479fe116e0062017d9496b8.tar.bz2
itools-0a1feb7c54e7167b0479fe116e0062017d9496b8.zip
fix indentation
Diffstat (limited to 'it_dbi_postgres.class')
-rw-r--r--it_dbi_postgres.class6
1 files changed, 3 insertions, 3 deletions
diff --git a/it_dbi_postgres.class b/it_dbi_postgres.class
index 8fc29f1..2f8eadb 100644
--- a/it_dbi_postgres.class
+++ b/it_dbi_postgres.class
@@ -62,7 +62,7 @@ function _get_field_defs()
$res = $this->query('SELECT * FROM information_schema.columns AS t ' . $where);
while ($res && ($field = $this->_fetch_assoc($res))) {
$result[$field['column_name']] = ['Field' => $field['column_name'], 'Type' => $field['data_type'], 'Extra' => it::match('^nextval\(', $field['column_default']) ? 'auto_increment' : '', 'Key' => $keys[$field['column_name']]];
- }
+ }
return $result;
}
@@ -96,7 +96,7 @@ function _query($query, $p)
if ($this->_p['keyfield'] && it::match('^INSERT ', $query)) {
$isinsert = true;
$query .= ' RETURNING ' . $this->_escape_name($this->_p['keyfield']);
- }
+ }
if (!($result = pg_query($this->_link, $query)) && $p['safety'])
{
/* TODO
@@ -111,7 +111,7 @@ function _query($query, $p)
$result = mysqli_query($this->_link, $query, $p['unbuffered'] ? MYSQLI_USE_RESULT : MYSQLI_STORE_RESULT);
}
*/
- }
+ }
$this->_affectedrows = pg_affected_rows($result);
$this->_insertid = $isinsert ? $this->_fetch_assoc($result)[$this->_p['keyfield']] : 0;