A junior dev once thought it would be funny to quietly slip this into some code right before a release not realizing it had changed in lollipop. He was lucky I happened to have Goat Simulator installed and caught it.
if (!userManager.isUserAGoat()) {
... Super important business logic ...
}
Comments
A junior dev once thought it would be funny to quietly slip this into some code right before a release not realizing it had changed in lollipop. He was lucky I happened to have Goat Simulator installed and caught it.
if (!userManager.isUserAGoat()) { ... Super important business logic ... }
public boolean isUserAGoat() { return mContext.getPackageManager() .isPackageAvailable("com.coffeestainstudios.goatsimulator"); }
I thought this was a joke at first, but this is apparently the genuine implementation: https://android.googlesource.com/platform/frameworks/base/+/...
Excellent :D Perhaps it should have been mountain goat, though?