Adding a proper detect