Very basic dependency injection (sort of)