]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/util.php
Merge branch 'master' of git://gitorious.org/laconica/br3nda into review/master
[quix0rs-gnu-social.git] / lib / util.php
index b17a44bd8538255fd348ed17433e24268ecd4bac..675ff51f016dd0a53b87b5cc9c227b5e5a5f9d97 100644 (file)
@@ -1321,3 +1321,16 @@ function common_compatible_license($from, $to)
     // XXX: better compatibility check needed here!
     return ($from == $to);
 }
+
+/**
+ * returns a quoted table name, if required according to config
+ */
+function common_database_tablename($tablename)
+{
+  
+  if(common_config('db','quote_identifiers')) {
+      $tablename = '"'. $tablename .'"';
+  }
+  //table prefixes could be added here later
+  return $tablename;
+}
\ No newline at end of file