module TsigApi
Public Class Methods
text_from_flash(str)
click to toggle source
extracts just the text from a tsig flash message
# File lib/tsig_api.rb, line 13 def self.text_from_flash(str) matches = /\<li\>(.+)\<\/li\>/im.match(str) messages = [] if matches messages = matches[1].split(/\<\/li\>\s*\<li\>/) end return messages end