Stage is not available yet if declared in the former position, so I moved the declaration to where it would be available.