Skip to content

Instantly share code, notes, and snippets.

View RomainLanz's full-sized avatar

Romain Lanz RomainLanz

View GitHub Profile
import type { HttpContext } from '@adonisjs/core/http'
import type { NextFn } from '@adonisjs/core/types/http'
export default class SilentAuthMiddleware {
async handle(ctx: HttpContext, next: NextFn) {
await ctx.auth.check()
return await next()
}
}
@RomainLanz
RomainLanz / .vimrc
Last active November 11, 2019 18:15
set nocompatible " Use VIM settings instead of Vi.
syntax enable " Enable syntax highlighting.
so ~/.vim/plugins.vim " Load all plugins.
"-------------Misc-------------"
set backspace=indent,eol,start " Make backspace behave like every other editor.
set tw=0 " Disable automatic linebreak.
set noerrorbells visualbell t_vb= " No damn bells!
set autowriteall " Automatically write the file when switching buffer.
'use strict'
const slug = require('@slynova/slug')
class Slugify {
register (model) {
const source = model.sluggable.source
const key = model.sluggable.key

Keybase proof

I hereby claim:

  • I am romainlanz on github.
  • I am romainlanz (https://keybase.io/romainlanz) on keybase.
  • I have a public key whose fingerprint is F308 851B 31C4 60CD C6C8 DBCE C3EB 9E14 664E 0863

To claim this, I am signing this object: