Added an if-function to check if the line matches