Fix: SQL Query scan device
This commit is contained in:
		@@ -24,7 +24,7 @@ func (db *DB) AllDevices() ([]*Device, error) {
 | 
			
		||||
	devices := make([]*Device, 0)
 | 
			
		||||
	for rows.Next() {
 | 
			
		||||
		device := new(Device)
 | 
			
		||||
		err := rows.Scan(&device.TOPIC, device.CustomerID, device.DeviceID, device.ProjectName, &device.MAC, &device.SN, &device.LastMsg)
 | 
			
		||||
		err := rows.Scan(&device.TOPIC, &device.CustomerID, &device.DeviceID, &device.ProjectName, &device.MAC, &device.SN, &device.LastMsg)
 | 
			
		||||
		if err != nil {
 | 
			
		||||
			return nil, err
 | 
			
		||||
		}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user