changes static veraible to local for dynamic updates