1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-24 07:39:43 +02:00

Add comments

This commit is contained in:
Harvey Kandola 2018-11-21 11:51:54 +00:00
parent 5d632712e0
commit c152d029f2
2 changed files with 3 additions and 4 deletions

View file

@ -91,7 +91,6 @@ func (s Store) GetOrganizationByDomain(subdomain string) (o org.Organization, er
if err == nil {
return
}
err = nil
// match on empty domain AS last resort
err = s.Runtime.Db.Get(&o, s.Bind(`SELECT id, c_refid AS refid,

View file

@ -26,9 +26,9 @@ type Context struct {
// Bind selects query parameter placeholder for given database provider.
//
// MySQL uses ?, ?, ? (default for all Documize queries)
// PostgreSQL uses $1, $2, $3
// MS SQL Server uses @p1, @p2, @p3
// MySQL uses ?, ?, ? (default for all Documize queries).``
// PostgreSQL uses $1, $2, $3.
// MS SQL Server uses @p1, @p2, @p3.
func (c *Context) Bind(sql string) string {
// Default to MySQL.
bindParam := sqlx.QUESTION