It is hard to interpret your code snippets out of context. Post the full code.