public function overwrite(&$old, $new) {
		if (!empty($old)) {
			foreach ($old as $key => $value) {
				if (!isset($new[$key])) {
					unset($old[$key]);
				}
			}
		}
		foreach ($new as $key => $value) {
			$old[$key] = $value;
		}
		return true;
	}
public function overwrite(&$old, $new) {
		if (!empty($old)) {
			foreach ($old as $key => $value) {
				if (!isset($new[$key])) {
					unset($old[$key]);
				}
			}
		}
		foreach ($new as $key => $value) {
			$old[$key] = $value;
		}
		return true;
	}
public function overwrite ( & $ old , $ new ) { if ( ! empty ( $ old ) ) { foreach ( $ old as $ key => $ value ) { if ( ! isset ( $ new [ $ key ] ) ) { unset ( $ old [ $ key ] ) ; } } } foreach ( $ new as $ key => $ value ) { $ old [ $ key ] = $ value ; } return true ; }
Overwrites session keys and values.

@param array $old Reference to the array that needs to be
overwritten. Will usually be `$_SESSION`.
@param array $new The data that should overwrite the keys/values in `$old`.
@return boolean Always `true`.
Overwrites session keys and values .