Fix error with ints, updated doc, added test