Simplification and bug fix.
Initial test for LOCALLY.