Use array_map() instead of walk.

Signed-off-by: Mior Muhammad Zaki <crynobone@gmail.com>
Merge branch '2.0'