Fix #16: Enhance regex in 'get destination of portdir' code block