Exemple #1
0
func GetAllGroups(db *periwinkle.Tx) []Group {
	var o []Group
	if result := db.Find(&o); result.Error != nil {
		if result.RecordNotFound() {
			return nil
		}
		dbError(result.Error)
	}
	return o
}
Exemple #2
0
func GetAllUsedTwilioNumbers(db *periwinkle.Tx) (ret []TwilioNumber) {
	var twilioNum []TwilioNumber
	if result := db.Find(&twilioNum); result.Error != nil {
		if result.RecordNotFound() {
			return nil
		}
		dbError(result.Error)
	}
	return twilioNum

}