-
-
Save tommarmstrong/9ba7ba17112d3ec0e102 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import db from '../database'; | |
class Item { | |
static fetch(user_id) { | |
db.query("select * from items where user_id = $1", user_id) | |
.then(function (result) { | |
console.log(result); | |
}) | |
.catch(function (error) { | |
console.log(error) | |
}); | |
} | |
} | |
export default Item; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment