<commit_before>package wireless

import (
	"os"
	"path"
	"path/filepath"
)

// Interfaces is a shortcut to the best known method for gathering the wireless
// interfaces from the current system
var Interfaces = SysFSInterfaces

// SysFSInterfaces returns the wireless interfaces found in the SysFS (/sys/class/net)
func SysFSInterfaces() []string {
	s := []string{}
	base := "/sys/class/net"
	matches, _ := filepath.Glob(path.Join(base, "*"))

	//  look for the wireless folder in each interfces directory to determine if it is a wireless device
	for _, iface := range matches {
		if _, err := os.Stat(path.Join(iface, "wireless")); err != nil {
			s = append(s, path.Base(iface))
		}
	}

	return s
}<commit_msg>fix bug with interface discovery<commit_after>package wireless

import (
	"os"
	"path"
	"path/filepath"
)

// Interfaces is a shortcut to the best known method for gathering the wireless
// interfaces from the current system
var Interfaces = SysFSInterfaces

// SysFSInterfaces returns the wireless interfaces found in the SysFS (/sys/class/net)
func SysFSInterfaces() []string {
	s := []string{}
	base := "/sys/class/net"
	matches, _ := filepath.Glob(path.Join(base, "*"))

	//  look for the wireless folder in each interfces directory to determine if it is a wireless device
	for _, iface := range matches {
		if _, err := os.Stat(path.Join(iface, "wireless")); err == nil {
			s = append(s, path.Base(iface))
		}
	}

	return s
}
{'fraction_non_alphanumeric': 0.12058212058212059, 'fraction_numerical': 0.0, 'mean_word_length': 3.9283276450511946, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1491133', 'n_tokens_mistral': 475, 'n_tokens_neox': 449, 'n_words': 160}