Skip to content

Instantly share code, notes, and snippets.

View joewebber's full-sized avatar

Joe Webber joewebber

View GitHub Profile
@joewebber
joewebber / bash.sh
Created September 9, 2025 13:24
Git reset after rebase
git reflog
git reset --hard HEAD@{n}
@joewebber
joewebber / app.js
Created September 8, 2025 18:33
Mocking Express middleware using Sinon
import express from "express";
import middleware from "./middleware.js";
const app = express();
const PORT = 3000;
app.use(express.json());
app.use((req, res, next) => {
@joewebber
joewebber / mysqli.class.php
Last active September 5, 2018 19:58
Simple MySQLi database class
<?php
/**
* MySQL database class
*
* Contains all functionality for database (MySQLi)
* Including select, insert, update, delete aand joins with conditions
*
*
*/