Skip to content

Instantly share code, notes, and snippets.

@rsalaza4
Last active March 20, 2024 18:15
Show Gist options
  • Save rsalaza4/99b03bec4374c3ccc484751c42a92560 to your computer and use it in GitHub Desktop.
Save rsalaza4/99b03bec4374c3ccc484751c42a92560 to your computer and use it in GitHub Desktop.
def get_email(self):
# Find all strings that follow emails conventions
match = re.search(r'[\w.+-]+@[\w-]+\.[\w.-]+', self.text)
# Assign word to email address
self.emailAddress = match.group(0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment