Fix formatting

This commit is contained in:
Linden committed 2021-10-25 03:48:14 +11:00
1 parent 5bcec3a0b1
commit 2b40fafa7f
7 files changed
+39 -40

No files matched your search

+6 -6
View File
@@ -4,8 +4,8 @@ title: Single
Returns the columns for a single row.
!!! info "Example"
=== "Lua
=== "Async"
=== "Lua"
**Async**
```lua
exports.oxmysql:single('SELECT * FROM users WHERE identifier = ?', {playerIdentifier}, function(result)
if result then
@@ -13,22 +13,22 @@ Returns the columns for a single row.
end
end)
```
=== "Sync"
**Sync**
```lua
local result = exports.oxmysql:singleSync('SELECT * FROM users WHERE identifier = ?', {playerIdentifier})
if result then
print(result.identifier, result.firstname, result.lastname)
end
```
=== "JavaScript
=== "Async"
=== "JavaScript"
**Async**
```js
exports.oxmysql.single('SELECT * FROM users WHERE identifier = ?', [playerIdentifier], function(result) {
if (result)
console.log(result.identifier, result.firstname, result.lastname)
})
```
=== "Sync"
**Sync**
```js
const result = exports.oxmysql.singleSync('SELECT * FROM users WHERE identifier = ?', [playerIdentifier]) {
if (result)