Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
5 / 5
100.00% covered (success)
100.00%
1 / 1
CRAP
100.00% covered (success)
100.00%
1 / 1
I18n
100.00% covered (success)
100.00%
5 / 5
100.00% covered (success)
100.00%
1 / 1
1
100.00% covered (success)
100.00%
1 / 1
 load_plugin_textdomain
100.00% covered (success)
100.00%
5 / 5
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2/**
3 * Define the internationalization functionality
4 *
5 * Loads and defines the internationalization files for this plugin
6 * so that it is ready for translation.
7 *
8 * @package brianhenryie/bh-wc-postcode-address-autofill
9 */
10
11namespace BrianHenryIE\WC_Postcode_Address_Autofill\WP_Includes;
12
13/**
14 * Define the internationalization functionality.
15 *
16 * Loads and defines the internationalization files for this plugin
17 * so that it is ready for translation.
18 */
19class I18n {
20
21    /**
22     * Load the plugin text domain for translation.
23     *
24     * @hooked plugins_loaded
25     */
26    public function load_plugin_textdomain(): void {
27
28        load_plugin_textdomain(
29            'bh-wc-postcode-address-autofill',
30            false,
31            plugin_basename( dirname( __DIR__, 2 ) ) . '/languages/'
32        );
33    }
34}