Match regex properly