Hardy type inequality in variable Lebesgue spaces